We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 23a3656 commit 18f4e23Copy full SHA for 18f4e23
Data/Map/Internal.hs
@@ -463,6 +463,11 @@ m1 \\ m2 = difference m1 m2
463
Size balanced trees.
464
--------------------------------------------------------------------}
465
-- | A Map from keys @k@ to values @a@.
466
+--
467
+-- The 'Semigroup' operation for 'Map' is 'union', which prefers
468
+-- values from the left operand. If @m1@ maps a key @k@ to a value
469
+-- @a1@, and @m2@ maps the same key to a different value @a2@, then
470
+-- their union @m1 <> m2@ maps @k@ to @a1@.
471
472
-- See Note: Order of constructors
473
data Map k a = Bin {-# UNPACK #-} !Size !k a !(Map k a) !(Map k a)
0 commit comments