Sourceval merge_by : ('a->'a-> int)->'a list->'a list->'a list
Sourceval mapMaybei' :
(Nat_big_num.num ->'a->'b option)->Nat_big_num.num ->'a list->'b list
mapMaybei f xs maps a function expecting an index (the position in the list * xs that it is currently viewing) and producing a maybe type across a list. * Elements that produce Nothing under f are discarded in the output, whilst * those producing Just e for some e are kept.
Sourceval mapMaybei : (Nat_big_num.num ->'a->'b option)->'a list->'b list
partitionii is xs returns a pair of lists: firstly those elements in xs that are at indices in is, and secondly the remaining elements. It preserves the order of elements in xs.
Sourceval filteri : Nat_big_num.num list->'a list->'a list
Sourceval filterii : Nat_big_num.num list->'a list->(Nat_big_num.num * 'a) list
Sourceval partitioni : Nat_big_num.num list->'a list->'a list * 'a list
Sourceval partitionii :
Nat_big_num.num list->'a list->(Nat_big_num.num * 'a) list * (Nat_big_num.num * 'a) list
Sourceval unzip3 : ('a * 'b * 'c) list->'a list * 'b list * 'c list
unzip3 ls takes a list of triples and returns a triple of lists.
Sourceval zip3 : 'a list->'b list->'c list->('a * 'b * 'c) list
zip3 ls takes a triple of lists and returns a list of triples.
split_string_on_char s c splits a string s into a list of substrings * on character c, otherwise returning the singleton list containing s * if c is not found in s. * * NOTE: quirkily, this doesn't discard separators (e.g. because NUL characters * are significant when indexing into string tables). FIXME: given this, is this * function really reusable? I suspect not.
padding_and_maybe_newline c w s creates enough of char c to pad string s to w characters, * unless s is of length w - 1 or greater, in which case it generates w copies preceded by a newline. * This style of formatting is used by the GNU linker in its link map output, so we * reproduce it using this function. Note that string s does not appear in the * output.
space_padding_and_maybe_newline w s creates enoughspaces to pad string s to w characters, * unless s is of length w - 1 or greater, in which case it generates w copies preceded by a newline. * This style of formatting is used by the GNU linker in its link map output, so we * reproduce it using this function. Note that string s does not appear in the * output.
padded_and_maybe_newline w s pads string s to w characters, using char c * unless s is of length w - 1 or greater, in which case the padding consists of * w copies of c preceded by a newline. * This style of formatting is used by the GNU linker in its link map output, so we * reproduce it using this function.
padding_to c w s creates enough copies of c to pad string s to w characters, * or 0 characters if s is of length w or greater. Note that string s does not appear in the * output.
space_padded_and_maybe_newline w s pads string s to w characters, using spaces, * unless s is of length w - 1 or greater, in which case the padding consists of * w spaces preceded by a newline. * This style of formatting is used by the GNU linker in its link map output, so we * reproduce it using this function.