diff --git a/doc/html/mp11.html b/doc/html/mp11.html index b1cc0c6..4a64ff4 100644 --- a/doc/html/mp11.html +++ b/doc/html/mp11.html @@ -157,6 +157,14 @@
mp_or<T...>
mp_any<T...>
<boost/mp11/bind.hpp>
mp_arg<I>
_1
,
+ ..., _9
mp_bind<F,
+ T...>
<boost/integer_sequence.hpp>
- A list is a — possibly but not necessarily variadic — template
+ A list is a — usually but not necessarily variadic — template
class whose parameters are all types, for example mp_list<char[],
void>
,
mp_list<>
,
@@ -251,6 +259,16 @@
struct N { static int constexpr value = 2; };+
+ A set is a list whose elements are unique. +
++ A map is a list of lists, the inner lists having at least + one element (the key.) The keys of the map must be unique. For example, +
+using M1 = std::tuple<std::pair<int, int*>, std::pair<float, float*>, std::pair<void, void*>>; +using M2 = mp_list<mp_list<int, int*>, mp_list<float>, mp_list<char, char[1], char[2]>>; +
mp_arg<I>
+template<std::size_t I> struct mp_arg; ++
+ mp_arg<I>
+ is a quoted metafunction whose nested template fn<T...>
returns the I
-th
+ zero-based element of T...
.
+
using _1 = mp_arg<0>; +using _2 = mp_arg<1>; +using _3 = mp_arg<2>; +using _4 = mp_arg<3>; +using _5 = mp_arg<4>; +using _6 = mp_arg<5>; +using _7 = mp_arg<6>; +using _8 = mp_arg<7>; +using _9 = mp_arg<8>; ++
+ _1
to _9
+ are placeholder types, the equivalent to the placeholders of boost::bind
.
+
template<template<class...> class F, class... T> struct mp_bind; ++
+ mp_bind<F, T...>
is a quoted metafunction that implements
+ the type-based equivalent of boost::bind
.
+ Its nested template fn<U...>
returns F<V...>
, where V...
is T...
with the placeholders replaced by the
+ corresponding element of U...
and the mp_bind
+ expressions replaced with their corresponding evaluations against U...
.
+
+ For example, mp_bind<F, int, _2, mp_bind<G, _1>>::fn<float, void>
+ is F<int, void, G<float>>
.
+
Last revised: March 25, 2017 at 01:01:08 GMT |
+Last revised: April 01, 2017 at 16:43:16 GMT |