@@ -1022,9 +1022,6 @@ mapMaybe f t = finishB (foldl' go emptyB t)
10221022--
10231023-- It's worth noting that the size of the result may be smaller if,
10241024-- for some @(x,y)@, @x \/= y && f x == f y@
1025- --
1026- -- If the function produces duplicate values, only one will be retained. No
1027- -- guarantee is made as to which.
10281025
10291026map :: Ord b => (a -> b ) -> Set a -> Set b
10301027map f t = finishB (foldl' (\ b x -> insertB (f x) b) emptyB t)
@@ -1173,9 +1170,6 @@ foldlFB = foldl
11731170--
11741171-- If the elements are in non-decreasing order, this function takes \(O(n)\)
11751172-- time.
1176- --
1177- -- If the list contains duplicate elements, only one will be retained. No
1178- -- guarantee is made as to which.
11791173fromList :: Ord a => [a ] -> Set a
11801174fromList xs = finishB (Foldable. foldl' (flip insertB) emptyB xs)
11811175{-# INLINE fromList #-} -- INLINE for fusion
@@ -1188,9 +1182,6 @@ fromList xs = finishB (Foldable.foldl' (flip insertB) emptyB xs)
11881182--------------------------------------------------------------------}
11891183-- | \(O(n)\). Build a set from an ascending list in linear time.
11901184--
1191- -- If the list contains duplicate elements, only one will be retained. No
1192- -- guarantee is made as to which.
1193- --
11941185-- __Warning__: This function should be used only if the elements are in
11951186-- non-decreasing order. This precondition is not checked. Use 'fromList' if the
11961187-- precondition may not hold.
@@ -1207,9 +1198,6 @@ fromAscList xs = ascLinkAll (Foldable.foldl' next Nada xs)
12071198
12081199-- | \(O(n)\). Build a set from a descending list in linear time.
12091200--
1210- -- If the list contains duplicate elements, only one will be retained. No
1211- -- guarantee is made as to which.
1212- --
12131201-- __Warning__: This function should be used only if the elements are in
12141202-- non-increasing order. This precondition is not checked. Use 'fromList' if the
12151203-- precondition may not hold.
0 commit comments