diff --git a/doc/mp11/algorithm.adoc b/doc/mp11/algorithm.adoc index c59a55a..37e32f5 100644 --- a/doc/mp11/algorithm.adoc +++ b/doc/mp11/algorithm.adoc @@ -567,11 +567,23 @@ using R3 = mp_flatten; // mp_list> template using mp_intersperse = /*...*/; -Inserts the separator `S` between the elements of `L`. +Inserts the separator `S` between the elements of the list `L`. `mp_intersperse, S>` is `L<>`. `mp_intersperse, S>` is `L`. `mp_intersperse, S>` is `L`. +## mp_split + + template using mp_split = /*...*/; + +Splits the list `L` into segments at each separator `S` and returns a list of +the segments. + +`mp_split, S>` is `L>`. `mp_split, S>`, where `S` does not occur in `T...`, +is `L>`. `mp_split, S>` is `L, L, L>`. + +The segments may be empty; `mp_split, S>` is `L, L, L<>, L<>>`. + ## mp_partition template class P> using mp_partition = /*...*/;