diff --git a/doc/html/mp11.html b/doc/html/mp11.html index 8994454..f419f7b 100644 --- a/doc/html/mp11.html +++ b/doc/html/mp11.html @@ -69,6 +69,10 @@
mp_rename<L, Y>
mp_append<L...>
+
mp_replace_front<L, T>
+
mp_replace_first<L, T>
+
mp_replace_second<L, T>
+
mp_replace_third<L, T>
Utility Components, <boost/mp11/utility.hpp>
@@ -92,7 +96,7 @@
mp_assign<L1, L2>
mp_clear<L>
mp_transform<F, L...>
-
mp_transform_if<P, F, L>
+
mp_transform_if<P, F, L...>
mp_fill<L, V>
mp_count<L, V>
mp_count_if<L, P>
@@ -111,6 +115,8 @@
mp_take<L, N>
mp_replace<L, V, W>
mp_replace_if<L, P, W>
+
mp_replace_at_c<L, I, W>
+
mp_replace_at<L, I, W>
mp_copy_if<L, P>
mp_remove<L, V>
mp_remove_if<L, P>
@@ -705,6 +711,58 @@ is an alias for L1<T1..., T2..., ..., Tn...>.

+
+ +
template<class L, class T> using mp_replace_front = /*...*/;
+
+

+ mp_replace_front<L, T> replaces the first element of the list + L with T. + That is, mp_replace_front<L<U1, U...>, + T> + is an alias for L<T, U...>. +

+
+
+ +
template<class L, class T> using mp_replace_first = mp_replace_front<L, T>;
+
+

+ mp_replace_first is another + name for mp_replace_front. +

+
+
+ +
template<class L, class T> using mp_replace_second = /*...*/;
+
+

+ mp_replace_second<L, T> replaces the second element of the + list L with T. That is, mp_replace_second<L<U1, U2, U...>, + T> + is an alias for L<U1, T, U...>. +

+
+
+ +
template<class L, class T> using mp_replace_third = /*...*/;
+
+

+ mp_replace_third<L, T> replaces the third element of the list + L with T. + That is, mp_replace_third<L<U1, U2, U3, U...>, + T> + is an alias for L<U1, U2, T, U...>. +

+

@@ -892,15 +950,17 @@

-
template<template<class...> class P, template<class...> class F, class L> using mp_transform_if = /*...*/;
+
template<template<class...> class P, template<class...> class F, class L...> using mp_transform_if = /*...*/;
 

- mp_transform_if replaces - the elements T of L for which mp_to_bool<P<T>> is mp_true - with F<T>, - and returns the result. + mp_transform_if<P, F, L1, L2, ..., Ln> + replaces the elements T + of the list L1 for which + mp_to_bool<P<T1, T2, ..., Tn>> is mp_true + with F<T1, T2, ..., Tn>, and returns the result, where Ti are the corresponding elements of + Li.

@@ -1119,6 +1179,30 @@
+
template<class L, std::size_t I, class W> using mp_replace_at_c = /*...*/;
+
+

+ Replaces the element of L + at zero-based index I with + W and returns the result. +

+
+
+ +
template<class L, class I, class W> using mp_replace_at = /*...*/;
+
+

+ Same as mp_replace_at_c, + but with a type argument I. + I::value must be a nonnegative number. +

+
+
+
template<class L, template<class...> class P> using mp_copy_if = /*...*/;
@@ -1604,7 +1688,7 @@
 
- +

Last revised: March 17, 2017 at 03:26:57 GMT

Last revised: March 18, 2017 at 18:33:25 GMT


diff --git a/doc/mp11/algorithm.qbk b/doc/mp11/algorithm.qbk index ad25649..f03b5c4 100644 --- a/doc/mp11/algorithm.qbk +++ b/doc/mp11/algorithm.qbk @@ -26,10 +26,11 @@ `mp_transform, L2, ..., Ln>` applies `F` to each successive tuple of elements and returns `L1...>`. [endsect] -[section `mp_transform_if`] - template class P, template class F, class L> using mp_transform_if = /*...*/; +[section `mp_transform_if`] + template class P, template class F, class L...> using mp_transform_if = /*...*/; -`mp_transform_if` replaces the elements `T` of `L` for which `mp_to_bool>` is `mp_true` with `F`, and returns the result. +`mp_transform_if` replaces the elements `T` of the list `L1` for which `mp_to_bool>` is `mp_true` with +`F`, and returns the result, where `Ti` are the corresponding elements of `Li`. [endsect] [section `mp_fill`] @@ -138,6 +139,18 @@ Replaces all `V` elements of `L` with `W` and returns the result. Replaces all `T` elements of `L` for which `mp_to_bool>` is `mp_true` with `W` and returns the result. [endsect] +[section `mp_replace_at_c`] + template using mp_replace_at_c = /*...*/; + +Replaces the element of `L` at zero-based index `I` with `W` and returns the result. +[endsect] + +[section `mp_replace_at`] + template using mp_replace_at = /*...*/; + +Same as `mp_replace_at_c`, but with a type argument `I`. `I::value` must be a nonnegative number. +[endsect] + [section `mp_copy_if`] template class P> using mp_copy_if = /*...*/; diff --git a/doc/mp11/list.qbk b/doc/mp11/list.qbk index 2f972ad..19f1677 100644 --- a/doc/mp11/list.qbk +++ b/doc/mp11/list.qbk @@ -92,4 +92,31 @@ is an alias for `L`. is an alias for `mp_list<>`. `mp_append, L2, ..., Ln>` is an alias for `L1`. [endsect] +[section `mp_replace_front`] + template using mp_replace_front = /*...*/; + +`mp_replace_front` replaces the first element of the list `L` with `T`. That is, `mp_replace_front, T>` is +an alias for `L`. +[endsect] + +[section `mp_replace_first`] + template using mp_replace_first = mp_replace_front; + +`mp_replace_first` is another name for `mp_replace_front`. +[endsect] + +[section `mp_replace_second`] + template using mp_replace_second = /*...*/; + +`mp_replace_second` replaces the second element of the list `L` with `T`. That is, `mp_replace_second, T>` +is an alias for `L`. +[endsect] + +[section `mp_replace_third`] + template using mp_replace_third = /*...*/; + +`mp_replace_third` replaces the third element of the list `L` with `T`. That is, `mp_replace_third, T>` +is an alias for `L`. +[endsect] + [endsect]