Since many function names (but not the type name) clash with
Prelude names, this module is usually imported qualified, e.g.

import Data.IntMap (IntMap)
import qualified Data.IntMap as IntMap

The implementation is based on big-endian patricia trees. This data
structure performs especially well on binary operations like union
and intersection. However, my benchmarks show that it is also
(much) faster on insertions and deletions when compared to a generic
size-balanced map implementation (see Data.Map).

Operation comments contain the operation time complexity in
the Big-O notation http://en.wikipedia.org/wiki/Big_O_notation.
Many operations have a worst-case complexity of O(min(n,W)).
This means that the operation can become linear in the number of
elements with a maximum of W -- the number of bits in an Int
(32 or 64).

O(min(n,W)). Insert with a combining function.
insertWith f key value mp
will insert the pair (key, value) into mp if key does
not exist in the map. If the key does exist, the function will
insert f new_value old_value.

O(min(n,W)). Insert with a combining function.
insertWithKey f key value mp
will insert the pair (key, value) into mp if key does
not exist in the map. If the key does exist, the function will
insert f key new_value old_value.

O(min(n,W)). Lookup and update.
The function returns original value, if it is updated.
This is different behavior than Data.Map.updateLookupWithKey.
Returns the original key value if the map entry is deleted.

O(n+m). Difference with a combining function. When two equal keys are
encountered, the combining function is applied to the key and both values.
If it returns Nothing, the element is discarded (proper set difference).
If it returns (Just y), the element is updated with a new value y.

O(n+m).
The expression (isSubmapOfBy f m1 m2) returns True if
all keys in m1 are in m2, and when f returns True when
applied to their respective values. For example, the following
expressions are all True:

O(n+m). Is this a proper submap? (ie. a submap but not equal).
The expression (isProperSubmapOfBy f m1 m2) returns True when
m1 and m2 are not equal,
all keys in m1 are in m2, and when f returns True when
applied to their respective values. For example, the following
expressions are all True:

O(n). The expression (showTreeWith hang wide map) shows
the tree that implements the map. If hang is
True, a hanging tree is shown otherwise a rotated tree is shown. If
wide is True, an extra wide version is shown.