partition package:ghc

Partition the map according to some predicate. The first map contains all elements that satisfy the predicate, the second all elements that fail the predicate. See also split.
partition (> "a") (fromList [(5,"a"), (3,"b")]) == (singleton 3 "b", singleton 5 "a")
partition (< "x") (fromList [(5,"a"), (3,"b")]) == (fromList [(3, "b"), (5, "a")], empty)
partition (> "x") (fromList [(5,"a"), (3,"b")]) == (empty, fromList [(3, "b"), (5, "a")])
partition the set according to some predicate.
Given a TyCon and a list of argument types, partition the arguments into:
  1. Inferred or Specified (i.e., invisible) arguments and
  2. Required (i.e., visible) arguments
Given a list of things paired with their visibilities, partition the things into (invisible things, visible things).
Partition the map according to some predicate. The first map contains all elements that satisfy the predicate, the second all elements that fail the predicate. See also split.
partitionWithKey (\ k _ -> k > 3) (fromList [(5,"a"), (3,"b")]) == (singleton 5 "a", singleton 3 "b")
partitionWithKey (\ k _ -> k < 7) (fromList [(5,"a"), (3,"b")]) == (fromList [(3, "b"), (5, "a")], empty)
partitionWithKey (\ k _ -> k > 7) (fromList [(5,"a"), (3,"b")]) == (empty, fromList [(3, "b"), (5, "a")])
Partition a list of HsDecls into function/pattern bindings, signatures, type family declarations, type family instances, and documentation comments. Panics when given a declaration that cannot be put into any of the output groups. The primary use of this function is to implement cvBindsAndSigs.
Split the LinkablePart lists in each Linkable into only object code files (.o, .a, .so) and only byte code, without LazyBCOs, and return two lists containing the nonempty Linkables for each.
Partitions the Messages and returns a tuple which first element are the warnings, and the second the errors.
Partition DVarSet according to the predicate given
partitionByList takes a list of Bools and a list of some elements and partitions the list according to the list of Bools. Elements corresponding to True go to the left; elements corresponding to False go to the right. For example, partitionByList [True, False, True] [1,2,3] == ([1,3], [2]) This function does not check whether the lists have equal length; when one list runs out, the function stops.
Uses a function to determine which of two output lists an input element should join