tibbe/unordered-containers — pull request #27 by basvandijk (2012-01-31 09:58:13+00:00)
Title: Added function insertLookupWithKey

Hi Johan,

Would you consider adding `insertLookupWithKey` to `unordered-containers`?

This function is similar to the equivalently named function in `Data.Map` and `Data.IntMap`.

O(min(n,W)). The expression (`insertLookupWithKey' f k x map`) is a pair where the first element is equal to (`lookup k map`) and the second element equal to (`insertWith' (f k) k x map`).

```haskell
insertLookupWithKey :: (Eq k, Hashable k)
=> (k -> v -> v -> v) -> k -> v -> HashMap k v
-> (Maybe v, HashMap k v)
```