Boost logo

Boost-Commit :

From: joel_at_[hidden]
Date: 2007-11-06 06:40:28


Author: djowel
Date: 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
New Revision: 40828
URL: http://svn.boost.org/trac/boost/changeset/40828

Log:
Regenerating/reorganizing docs
Added:
   trunk/libs/fusion/doc/algorithm.qbk
      - copied, changed from r40827, /trunk/libs/fusion/doc/algorithms.qbk
Removed:
   trunk/libs/fusion/doc/algorithms.qbk
   trunk/libs/fusion/doc/html/fusion/
Text files modified:
   trunk/libs/fusion/doc/adapted.qbk | 6
   trunk/libs/fusion/doc/algorithm.qbk | 141 +++-
   trunk/libs/fusion/doc/container.qbk | 1213 +++++++++++++++++++++++++++++++++++++++
   trunk/libs/fusion/doc/extension.qbk | 3
   trunk/libs/fusion/doc/functional.qbk | 12
   trunk/libs/fusion/doc/fusion.qbk | 182 +++---
   trunk/libs/fusion/doc/organization.qbk | 5
   trunk/libs/fusion/doc/quick_start.qbk | 2
   trunk/libs/fusion/doc/sequence.qbk | 1191 --------------------------------------
   trunk/libs/fusion/doc/support.qbk | 7
   trunk/libs/fusion/doc/view.qbk | 8
   11 files changed, 1466 insertions(+), 1304 deletions(-)

Modified: trunk/libs/fusion/doc/adapted.qbk
==============================================================================
--- trunk/libs/fusion/doc/adapted.qbk (original)
+++ trunk/libs/fusion/doc/adapted.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -12,6 +12,7 @@
 [heading Header]
 
     #include <boost/fusion/adapted.hpp>
+ #include <boost/fusion/include/adapted.hpp>
 
 [section std::pair]
 
@@ -21,6 +22,7 @@
 [heading Header]
 
     #include <boost/fusion/adapted/std_pair.hpp>
+ #include <boost/fusion/include/std_pair.hpp>
 
 [heading Model of]
 
@@ -47,6 +49,7 @@
 [heading Header]
 
     #include <boost/fusion/adapted/mpl.hpp>
+ #include <boost/fusion/include/mpl.hpp>
 
 [heading Model of]
 
@@ -79,6 +82,7 @@
 [heading Header]
 
     #include <boost/fusion/adapted/array.hpp>
+ #include <boost/fusion/include/array.hpp>
 
 [heading Model of]
 
@@ -107,6 +111,7 @@
 [heading Header]
 
     #include <boost/fusion/adapted/boost_tuple.hpp>
+ #include <boost/fusion/include/boost_tuple.hpp>
 
 [heading Model of]
 
@@ -134,6 +139,7 @@
 [heading Header]
 
     #include <boost/fusion/adapted/variant.hpp>
+ #include <boost/fusion/include/variant.hpp>
 
 [heading Model of]
 

Copied: trunk/libs/fusion/doc/algorithm.qbk (from r40827, /trunk/libs/fusion/doc/algorithms.qbk)
==============================================================================
--- /trunk/libs/fusion/doc/algorithms.qbk (original)
+++ trunk/libs/fusion/doc/algorithm.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -1,51 +1,54 @@
-[section Algorithms]
+[section Algorithm]
+
 [heading Lazy Evaluation]
 
-Unlike __mpl__, Fusion algorithms are lazy and non sequence-type
-preserving. What does that mean? It means that when you operate on a
-sequence through a Fusion algorithm that returns a sequence, the sequence
-returned may not be of the same class as the original. This is by design.
-Runtime efficiency is given a high priority. Like __mpl__, and unlike
-__stl__, fusion algorithms are functional in nature such that algorithms
-are non mutating (no side effects). However, due to the high cost of
-returning full sequences such as vectors and lists, /Views/ are returned
-from Fusion algorithms instead. For example, the __transform__ algorithm
-does not actually return a transformed version of the original sequence.
-__transform__ returns a __transform_view__. This view holds a reference to
-the original sequence plus the transform function. Iteration over the
-__transform_view__ will apply the transform function over the sequence
-elements on demand. This /lazy/ evaluation scheme allows us to chain as
+Unlike __mpl__, Fusion algorithms are lazy and non sequence-type
+preserving. What does that mean? It means that when you operate on a
+sequence through a Fusion algorithm that returns a sequence, the sequence
+returned may not be of the same class as the original. This is by design.
+Runtime efficiency is given a high priority. Like __mpl__, and unlike
+__stl__, fusion algorithms are functional in nature such that algorithms
+are non mutating (no side effects). However, due to the high cost of
+returning full sequences such as vectors and lists, /Views/ are returned
+from Fusion algorithms instead. For example, the __transform__ algorithm
+does not actually return a transformed version of the original sequence.
+__transform__ returns a __transform_view__. This view holds a reference to
+the original sequence plus the transform function. Iteration over the
+__transform_view__ will apply the transform function over the sequence
+elements on demand. This /lazy/ evaluation scheme allows us to chain as
 many algorithms as we want without incurring a high runtime penalty.
 
 [heading Sequence Extension]
 
-The /lazy/ evaluation scheme where __algorithms__ return __views__ also
-allows operations such as __push_back__ to be totally generic. In Fusion,
-__push_back__ is actually a generic algorithm that works on all sequences.
-Given an input sequence `s` and a value `x`, Fusion's __push_back__
-algorithm simply returns a __joint_view__: a view that holds a reference to
-the original sequence `s` and the value `x`. Functions that were once
-sequence specific and need to be implemented N times over N different
-sequences are now implemented only once. That is to say that Fusion
-sequences are cheaply extensible. However, an important caveat is that the
-result of a sequence extending operation like __push_back__ does not retain
-the properties of the original sequence such as associativity of __set__s.
-To regain the original sequence, __conversion__ functions are provided. You
-may use one of the __conversion__ functions to convert back to the original
+The /lazy/ evaluation scheme where __algorithms__ return __views__ also
+allows operations such as __push_back__ to be totally generic. In Fusion,
+__push_back__ is actually a generic algorithm that works on all sequences.
+Given an input sequence `s` and a value `x`, Fusion's __push_back__
+algorithm simply returns a __joint_view__: a view that holds a reference to
+the original sequence `s` and the value `x`. Functions that were once
+sequence specific and need to be implemented N times over N different
+sequences are now implemented only once. That is to say that Fusion
+sequences are cheaply extensible. However, an important caveat is that the
+result of a sequence extending operation like __push_back__ does not retain
+the properties of the original sequence such as associativity of __set__s.
+To regain the original sequence, __conversion__ functions are provided. You
+may use one of the __conversion__ functions to convert back to the original
 sequence type.
 
 [heading Header]
 
     #include <boost/fusion/algorithm.hpp>
+ #include <boost/fusion/include/algorithm.hpp>
 
 [section Iteration]
 
-The iteration algorithms provide the fundamental algorithms for traversing
+The iteration algorithms provide the fundamental algorithms for traversing
 a sequence repeatedly applying an operation to its elements.
 
 [heading Header]
 
     #include <boost/fusion/algorithm/iteration.hpp>
+ #include <boost/fusion/include/iteration.hpp>
 
 [section Functions]
 
@@ -83,6 +86,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/iteration/fold.hpp>
+ #include <boost/fusion/include/fold.hpp>
 
 [heading Example]
     struct make_string
@@ -135,6 +139,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/iteration/accumulate.hpp>
+ #include <boost/fusion/include/accumulate.hpp>
 
 [heading Example]
     struct make_string
@@ -185,6 +190,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/iteration/for_each.hpp>
+ #include <boost/fusion/include/for_each.hpp>
 
 [heading Example]
     struct increment
@@ -242,6 +248,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/iteration/fold.hpp>
+ #include <boost/fusion/include/fold.hpp>
 
 [endsect]
 
@@ -281,6 +288,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/iteration/accumulate.hpp>
+ #include <boost/fusion/include/accumulate.hpp>
 
 [endsect]
 
@@ -320,6 +328,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/iteration/for_each.hpp>
+ #include <boost/fusion/include/for_each.hpp>
 
 [endsect]
 
@@ -333,6 +342,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query.hpp>
+ #include <boost/fusion/include/query.hpp>
 
 [section Functions]
 
@@ -368,6 +378,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/any.hpp>
+ #include <boost/fusion/include/any.hpp>
 
 [heading Example]
     struct odd
@@ -416,6 +427,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/all.hpp>
+ #include <boost/fusion/include/all.hpp>
 
 [heading Example]
     struct odd
@@ -464,6 +476,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/none.hpp>
+ #include <boost/fusion/include/none.hpp>
 
 [heading Example]
     struct odd
@@ -483,7 +496,7 @@
 [section find]
 
 [heading Description]
-Finds the first element of a given type within a sequence.
+Finds the first element of a given type within a sequence.
 
 [heading Synopsis]
     template<
@@ -518,6 +531,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/find.hpp>
+ #include <boost/fusion/include/find.hpp>
 
 [heading Example]
     const __vector__<char,int> vec('a','0');
@@ -527,7 +541,7 @@
 [endsect]
 
 [section find_if]
-Finds the first element within a sequence with a type for which a given __mpl_lambda_expression__ evaluates to
+Finds the first element within a sequence with a type for which a given __mpl_lambda_expression__ evaluates to
 `boost::mpl::true_`.
 
 [heading Description]
@@ -556,7 +570,7 @@
 
 [*Return type]: An iterator of the same iterator category as the iterators of `seq`.
 
-[*Semantics]: Returns the first element of `seq` for which __mpl_lambda_expression__ `F` evaluates to `boost::mpl::true_`,
+[*Semantics]: Returns the first element of `seq` for which __mpl_lambda_expression__ `F` evaluates to `boost::mpl::true_`,
 or `__end__(seq)` if there is no such element.
 
 [heading Complexity]
@@ -604,6 +618,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/count.hpp>
+ #include <boost/fusion/include/count.hpp>
 
 [heading Example]
     const __vector__<double,int,int> vec(1.0,2,3);
@@ -614,7 +629,7 @@
 [section count_if]
 
 [heading Description]
-Returns the number of elements within a sequence with a type for which a given unary function object evaluates to
+Returns the number of elements within a sequence with a type for which a given unary function object evaluates to
 `true`.
 
 [heading Synopsis]
@@ -644,6 +659,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/count_if.hpp>
+ #include <boost/fusion/include/count_if.hpp>
 
 [heading Example]
     const __vector__<int,int,int> vec(1,2,3);
@@ -689,6 +705,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/any.hpp>
+ #include <boost/fusion/include/any.hpp>
 
 [endsect]
 
@@ -726,6 +743,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/all.hpp>
+ #include <boost/fusion/include/all.hpp>
 
 [endsect]
 
@@ -763,6 +781,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/none.hpp>
+ #include <boost/fusion/include/none.hpp>
 
 [endsect]
 
@@ -800,6 +819,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/find.hpp>
+ #include <boost/fusion/include/find.hpp>
 
 [endsect]
 
@@ -837,6 +857,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/find_if.hpp>
+ #include <boost/fusion/include/find_if.hpp>
 
 [endsect]
 
@@ -874,6 +895,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/count.hpp>
+ #include <boost/fusion/include/count.hpp>
 
 [endsect]
 
@@ -911,6 +933,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/query/count_if.hpp>
+ #include <boost/fusion/include/count_if.hpp>
 
 [endsect]
 
@@ -928,6 +951,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation.hpp>
+ #include <boost/fusion/include/transformation.hpp>
 
 [section Functions]
 
@@ -952,7 +976,7 @@
 [heading Expression Semantics]
     __filter__<T>(seq);
 
-[*Return type]: A model of __forward_sequence__.
+[*Return type]: A model of __forward_sequence__.
 
 [*Semantics]: Returns a sequence containing all the elements of `seq` of type `T`.
 Equivalent to `__filter_if__<boost::same_type<_, T> >(seq)`.
@@ -963,6 +987,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/filter.hpp>
+ #include <boost/fusion/include/filter.hpp>
 
 [heading Example]
     const __vector__<int,int,long,long> vec(1,2,3,4);
@@ -1003,6 +1028,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/filter_if.hpp>
+ #include <boost/fusion/include/filter_if.hpp>
 
 [heading Example]
     const __vector__<int,int,double,double> vec(1,2,3.0,4.0);
@@ -1063,6 +1089,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/transform.hpp>
+ #include <boost/fusion/include/transform.hpp>
 
 [heading Example]
     struct triple
@@ -1112,6 +1139,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/replace.hpp>
+ #include <boost/fusion/include/replace.hpp>
 
 [heading Example]
     assert(__replace__(__make_vector__(1,2), 2, 3) == __make_vector__(1,3));
@@ -1144,7 +1172,7 @@
 
 [*Return type]: A model of __forward_sequence__.
 
-[*Semantics]: Returns a new sequence with all the elements of `seq`,
+[*Semantics]: Returns a new sequence with all the elements of `seq`,
 with `new_value` assigned to each element for which `f` evaluates to `true`.
 
 [heading Complexity]
@@ -1153,6 +1181,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/replace_if.hpp>
+ #include <boost/fusion/include/replace_if.hpp>
 
 [heading Example]
     struct odd
@@ -1189,7 +1218,7 @@
 [heading Expression Semantics]
     __remove__<T>(seq);
 
-[*Return type]: A model of __forward_sequence__.
+[*Return type]: A model of __forward_sequence__.
 
 [*Semantics]: Returns a new sequence, containing all the elements of `seq`, in their original order, except
 those of type `T`. Equivalent to `__remove_if__<boost::is_same<_,T> >(seq)`.
@@ -1200,6 +1229,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/remove.hpp>
+ #include <boost/fusion/include/remove.hpp>
 
 [heading Example]
     const __vector__<int,double> vec(1,2.0);
@@ -1229,10 +1259,10 @@
 [heading Expression Semantics]
     __remove_if__<Pred>(seq);
 
-[*Return type]: A model of __forward_sequence__.
+[*Return type]: A model of __forward_sequence__.
 
 [*Semantics]: Returns a new sequence, containing all the elements of `seq`, in their original order, except
-those elements with types for which `Pred` evaluates to `boost::mpl::true_`.
+those elements with types for which `Pred` evaluates to `boost::mpl::true_`.
 Equivalent to `__filter__<boost::mpl::not_<Pred> >(seq)`.
 
 [heading Complexity]
@@ -1241,6 +1271,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/remove_if.hpp>
+ #include <boost/fusion/include/remove_if.hpp>
 
 [heading Example]
     const __vector__<int,double> vec(1,2.0);
@@ -1277,6 +1308,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/reverse.hpp>
+ #include <boost/fusion/include/reverse.hpp>
 
 [heading Example]
     assert(__reverse__(__make_vector__(1,2,3)) == __make_vector__(3,2,1));
@@ -1312,6 +1344,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/clear.hpp>
+ #include <boost/fusion/include/clear.hpp>
 
 [heading Example]
     assert(__clear__(__make_vector__(1,2,3)) == __make_vector__());
@@ -1367,6 +1400,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/erase.hpp>
+ #include <boost/fusion/include/erase.hpp>
 
 [heading Example]
     const __vector__<int, double, char> vec(1, 2.0, 'c');
@@ -1407,6 +1441,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/erase_key.hpp>
+ #include <boost/fusion/include/erase_key.hpp>
 
 [heading Example]
     assert(__erase_key__<int>(__make_map__<int, long>('a', 'b')) == __make_map__<long>('b'));
@@ -1448,6 +1483,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/insert.hpp>
+ #include <boost/fusion/include/insert.hpp>
 
 [heading Example]
     const __vector__<int,int> vec(1,2);
@@ -1490,6 +1526,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/insert_range.hpp>
+ #include <boost/fusion/include/insert_range.hpp>
 
 [heading Example]
     const __vector__<int,int> vec(1,2);
@@ -1527,6 +1564,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/join.hpp>
+ #include <boost/fusion/include/join.hpp>
 
 [heading Example]
     __vector__<int,char> v1(1, 'a');
@@ -1547,7 +1585,7 @@
         ...
         typename SequenceN
>
- typename __result_of_zip__<Sequence1, Sequence2, ... SequenceN>::type
+ typename __result_of_zip__<Sequence1, Sequence2, ... SequenceN>::type
     zip(Sequence1 const& seq1, Sequence2 const& seq2, ... SequenceN const& seqN);
 
 [table Parameters
@@ -1568,6 +1606,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/zip.hpp>
+ #include <boost/fusion/include/zip.hpp>
 
 [heading Example]
     __vector__<int,char> v1(1, 'a');
@@ -1579,7 +1618,7 @@
 [section pop_back]
 
 [heading Description]
-Returns a new sequence, with the last element of the original removed.
+Returns a new sequence, with the last element of the original removed.
 
 [heading Synopsis]
     template<
@@ -1605,6 +1644,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/pop_back.hpp>
+ #include <boost/fusion/include/pop_back.hpp>
 
 [heading Example]
     assert(___pop_back__(__make_vector__(1,2,3)) == __make_vector__(1,2));
@@ -1641,6 +1681,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/pop_front.hpp>
+ #include <boost/fusion/include/pop_front.hpp>
 
 [heading Example]
     assert(__pop_front__(__make_vector__(1,2,3)) == __make_vector__(2,3));
@@ -1679,6 +1720,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/push_back.hpp>
+ #include <boost/fusion/include/push_back.hpp>
 
 [heading Example]
     assert(__push_back__(__make_vector__(1,2,3),4) == __make_vector__(1,2,3,4));
@@ -1717,6 +1759,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/push_front.hpp>
+ #include <boost/fusion/include/push_front.hpp>
 
 [heading Example]
     assert(__push_front__(__make_vector__(1,2,3),0) == __make_vector__(0,1,2,3));
@@ -1761,6 +1804,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/filter.hpp>
+ #include <boost/fusion/include/filter.hpp>
 
 [endsect]
 
@@ -1798,6 +1842,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/filter_if.hpp>
+ #include <boost/fusion/include/filter_if.hpp>
 
 [endsect]
 
@@ -1854,6 +1899,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/transform.hpp>
+ #include <boost/fusion/include/transform.hpp>
 
 [heading Example]
     struct triple
@@ -1888,7 +1934,7 @@
 [table Parameters
     [[Parameter][Requirement][Description]]
     [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`T`][Any type][The type of the search and replacement objects]]
+ [[`T`][Any type][The type of the search and replacement objects]]
 ]
 
 [heading Expression Semantics]
@@ -1904,6 +1950,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/replace.hpp>
+ #include <boost/fusion/include/replace.hpp>
 
 [endsect]
 
@@ -1942,6 +1989,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/replace_if.hpp>
+ #include <boost/fusion/include/replace_if.hpp>
 
 [endsect]
 
@@ -1979,6 +2027,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/remove.hpp>
+ #include <boost/fusion/include/remove.hpp>
 
 [endsect]
 
@@ -2016,6 +2065,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/remove_if.hpp>
+ #include <boost/fusion/include/remove_if.hpp>
 
 [endsect]
 
@@ -2051,6 +2101,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/reverse.hpp>
+ #include <boost/fusion/include/reverse.hpp>
 
 [endsect]
 
@@ -2086,6 +2137,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/clear.hpp>
+ #include <boost/fusion/include/clear.hpp>
 
 [endsect]
 
@@ -2130,6 +2182,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/erase.hpp>
+ #include <boost/fusion/include/erase.hpp>
 
 [endsect]
 
@@ -2167,6 +2220,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/erase_key.hpp>
+ #include <boost/fusion/include/erase_key.hpp>
 
 [endsect]
 
@@ -2206,6 +2260,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/insert.hpp>
+ #include <boost/fusion/include/insert.hpp>
 
 [endsect]
 
@@ -2245,6 +2300,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/insert_range.hpp>
+ #include <boost/fusion/include/insert_range.hpp>
 
 [endsect]
 
@@ -2276,6 +2332,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/join.hpp>
+ #include <boost/fusion/include/join.hpp>
 
 [endsect]
 
@@ -2309,6 +2366,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/transformation/zip.hpp>
+ #include <boost/fusion/include/zip.hpp>
 
 [endsect]
 
@@ -2344,6 +2402,7 @@
 [heading Header]
 
     #include <boost/fusion/algorithm/tranformation/pop_back.hpp>
+ #include <boost/fusion/include/pop_back.hpp>
 
 [endsect]
 

Deleted: trunk/libs/fusion/doc/algorithms.qbk
==============================================================================
--- trunk/libs/fusion/doc/algorithms.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
+++ (empty file)
@@ -1,2457 +0,0 @@
-[section Algorithms]
-[heading Lazy Evaluation]
-
-Unlike __mpl__, Fusion algorithms are lazy and non sequence-type
-preserving. What does that mean? It means that when you operate on a
-sequence through a Fusion algorithm that returns a sequence, the sequence
-returned may not be of the same class as the original. This is by design.
-Runtime efficiency is given a high priority. Like __mpl__, and unlike
-__stl__, fusion algorithms are functional in nature such that algorithms
-are non mutating (no side effects). However, due to the high cost of
-returning full sequences such as vectors and lists, /Views/ are returned
-from Fusion algorithms instead. For example, the __transform__ algorithm
-does not actually return a transformed version of the original sequence.
-__transform__ returns a __transform_view__. This view holds a reference to
-the original sequence plus the transform function. Iteration over the
-__transform_view__ will apply the transform function over the sequence
-elements on demand. This /lazy/ evaluation scheme allows us to chain as
-many algorithms as we want without incurring a high runtime penalty.
-
-[heading Sequence Extension]
-
-The /lazy/ evaluation scheme where __algorithms__ return __views__ also
-allows operations such as __push_back__ to be totally generic. In Fusion,
-__push_back__ is actually a generic algorithm that works on all sequences.
-Given an input sequence `s` and a value `x`, Fusion's __push_back__
-algorithm simply returns a __joint_view__: a view that holds a reference to
-the original sequence `s` and the value `x`. Functions that were once
-sequence specific and need to be implemented N times over N different
-sequences are now implemented only once. That is to say that Fusion
-sequences are cheaply extensible. However, an important caveat is that the
-result of a sequence extending operation like __push_back__ does not retain
-the properties of the original sequence such as associativity of __set__s.
-To regain the original sequence, __conversion__ functions are provided. You
-may use one of the __conversion__ functions to convert back to the original
-sequence type.
-
-[heading Header]
-
- #include <boost/fusion/algorithm.hpp>
-
-[section Iteration]
-
-The iteration algorithms provide the fundamental algorithms for traversing
-a sequence repeatedly applying an operation to its elements.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/iteration.hpp>
-
-[section Functions]
-
-[section fold]
-
-[heading Description]
-For a sequence `Seq`, initial state, and binary function object or function pointer `f`, fold repeatedly applies binary `f` to each element of `Seq` and the previous state.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename State,
- typename F
- >
- typename __result_of_fold__<Sequence, State, F>::type fold(
- Sequence& seq, State const& initial_state, F const& f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__,`f(e,s)` must be a valid expression for each element `e` in `seq`, and current state `s`][Operation's argument]]
- [[`initial_state`][Any type][Initial state]]
- [[`f`][`__boost_result_of_call__<F(E,S)>::type` is the return type of `f(e,s)` for each element `e` of type `E` in `seq`, and current state `s` of type `S`][Operation's argument]]
-]
-
-[heading Expression Semantics]
- fold(seq, initial_state, f);
-
-[*Return type]: Any type
-
-[*Semantics]: Equivalent to `f(eN ....f(e2,f(e1,initial_state)))` where `e1 ...eN` are the elements of `seq`.
-
-[heading Complexity]
-Linear, exactly `__result_of_size__<Sequence>::value` applications of `f`.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/iteration/fold.hpp>
-
-[heading Example]
- struct make_string
- {
- typedef std::string result_type;
-
- template<typename T>
- std::string operator()(const T& t, const std::string& str) const
- {
- return str + boost::lexical_cast<std::string>(t);
- }
- };
- ...
- const __vector__<int,int> vec(1,2);
- assert(__fold__(vec,std::string(""), make_string()) == "12");
-
-[endsect]
-
-[section accumulate]
-
-[heading Description]
-For a sequence `Seq`, initial state, and binary function object or function pointer `f`, accumulate repeatedly applies binary `f` to each element of `Seq` and the previous state.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename State,
- typename F
- >
- typename __result_of_accumulate__<Sequence, State, F>::type accumulate(
- Sequence& seq, State const& initial_state, F const& f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `f(eN ....f(e2,f(e1,initial_state)))` must be a valid expression for each element `e1` to `eN` in `seq`][Operation's argument]]
- [[`initial_state`][Any type][Initial state]]
- [[`f`][`__boost_result_of_call__<F(E,S)>::type` is the return type of `f(e,s)` for each element `e` of type `E` in `seq`, and current state `s` of type `S`][Operation's argument]]
-]
-
-[heading Expression Semantics]
- accumulate(seq, initial_state, f);
-
-[*Return type]: Any type
-
-[*Semantics]: Equivalent to `f(eN ....f(e2,f(e1,initial_state)))` where `e1 ...eN` are the elements of `seq`.
-
-[heading Complexity]
-Linear, exactly `__result_of_size__<Sequence>::value` applications of `f`.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/iteration/accumulate.hpp>
-
-[heading Example]
- struct make_string
- {
- typedef std::string result_type;
-
- template<typename T>
- std::string operator()(const T& t, const std::string& str) const
- {
- return str + boost::lexical_cast<std::string>(t);
- }
- };
- ...
- const __vector__<int,int> vec(1,2);
- assert(__accumulate__(vec,std::string(""), make_string()) == "12");
-
-[endsect]
-
-[section for_each]
-
-[heading Description]
-Applies a unary function object to each element of a sequence.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- typename __result_of_for_each__<Sequence, F>::type for_each(
- Sequence& seq, F const& f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `f(e)` must be a valid expression for each element `e` in `seq`][Operation's argument]]
- [[`f`][A unary __reg_callable_obj__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __for_each__(seq, f);
-
-[*Return type]: `void`
-
-[*Semantics]: Calls `f(e)` for each element `e` in `seq`.
-
-[heading Complexity]
-Linear, exactly `__result_of_size__<Sequence>::value` applications of `f`.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/iteration/for_each.hpp>
-
-[heading Example]
- struct increment
- {
- template<typename T>
- void operator()(T& t) const
- {
- ++t;
- }
- };
- ...
- __vector__<int,int> vec(1,2);
- __for_each__(vec, increment());
- assert(vec == __make_vector__(2,3));
-
-[endsect]
-
-[endsect]
-
-[section Metafunctions]
-
-[section fold]
-
-[heading Description]
-Returns the result type of __fold__.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename State,
- typename F>
- struct fold
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [The sequence to iterate]]
- [[`State`] [Any type] [The initial state for the first application of `F`]]
- [[`F`] [`__boost_result_of_call__<F(E,S)>::type` is the return type of `f(e,s)` for each element `e` of type `E` in `seq`, and current state `s` of type `S`] [The operation to be applied on forward traversal]]
-]
-
-[heading Expression Semantics]
- __result_of_fold__<Sequence, State, F>::type
-
-[*Return type]: Any type
-
-[*Semantics]: Returns the result of applying `fold` to a sequence of type `Sequence`, with an initial state of
-type `State` and binary function object or function pointer of type `F`.
-
-[heading Complexity]
-Linear, exactly `__result_of_size__<Sequence>::value` applications of `F`.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/iteration/fold.hpp>
-
-[endsect]
-
-[section accumulate]
-
-[heading Description]
-Returns the result type of __accumulate__.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename State,
- typename F>
- struct accumulate
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [The sequence to iterate]]
- [[`State`] [Any type] [The initial state for the first application of `F`]]
- [[`F`] [`__boost_result_of_call__<F(E,S)>::type` is the return type of `f(e,s)` for each element `e` of type `E` in `seq`, and current state `s` of type `S`] [The operation to be applied on forward traversal]]
-]
-
-[heading Expression Semantics]
- __result_of_accumulate__<Sequence, State, F>::type
-
-[*Return type]: Any type
-
-[*Semantics]: Returns the result of applying `accumulate` to a sequence of type `Sequence`, with an initial state of
-type `State` and binary function object or function pointer of type `F`.
-
-[heading Complexity]
-Linear, exactly `__result_of_size__<Sequence>::value` applications of `F`.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/iteration/accumulate.hpp>
-
-[endsect]
-
-[section for_each]
-A metafunction returning the result type of applying __for_each__ to a sequence. The
-return type of __for_each__ is always `void`.
-
-[heading Description]
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- struct for_each
- {
- typedef void type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [Operation's argument]]
- [[`F`] [Any type] [Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_for_each__<Sequence, F>::type
-
-[*Return type]: `void`.
-
-[*Semantics]: Returns the return type of __for_each__ for a sequence of type `Sequence` and a unary function object `F`.
-The return type is always `void`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/iteration/for_each.hpp>
-
-[endsect]
-
-[endsect]
-
-[endsect]
-
-[section Query]
-The query algorithms provide support for searching and analyzing sequences.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query.hpp>
-
-[section Functions]
-
-[section any]
-
-[heading Description]
-For a sequence `seq` and unary function object `f`, `any` returns true if `f` returns true for at least one element of `seq`.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- typename __result_of_any__<Sequence,F>::type any(
- Sequence const& seq, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `f(e)` must be a valid expression, convertible to `bool`, for each element `e` in `seq`][The sequence to search]]
- [[`f`][A unary function object][The search predicate]]
-]
-
-[heading Expression semantics]
- __any__(seq, f);
-
-[*Return type]: `bool`
-
-[*Semantics]: Returns true if and only if `f(e)` evaluates to `true` for some element `e` in `seq`.
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/any.hpp>
-
-[heading Example]
- struct odd
- {
- template<typename T>
- bool operator()(T t) const
- {
- return t % 2;
- }
- };
- ...
- assert(__any__(__make_vector__(1,2), odd()));
- assert(!__any__(__make_vector__(2,4), odd()));
-
-[endsect]
-
-[section all]
-
-[heading Description]
-For a sequence `seq` and unary function object `f`, `all` returns true if `f` returns true for every element of `seq`.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- typename __result_of_all__<Sequence,F>::type all(
- Sequence const& seq, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `f(e)` is a valid expression, convertible to `bool`, for every element `e` in `seq`][The sequence to search]]
- [[`f`][A unary function object][The search predicate]]
-]
-
-[heading Expression Semantics]
- __all__(seq, f);
-
-[*Return type]: `bool`
-
-[*Semantics]: Returns true if and only if `f(e)` evaluates to `true` for every element `e` in `seq`.
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/all.hpp>
-
-[heading Example]
- struct odd
- {
- template<typename T>
- bool operator()(T t) const
- {
- return t % 2;
- }
- };
- ...
- assert(__all__(__make_vector__(1,3), odd()));
- assert(!__all__(__make_vector__(1,2), odd()));
-
-[endsect]
-
-[section none]
-
-[heading Description]
-For a sequence `seq` and unary function object `f`, `none` returns true if `f` returns false for every element of `seq`.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- typename __result_of_none__<Sequence,F>::type none(
- Sequence const& seq, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `f(e)` is a valid expression, convertible to `bool`, for every element `e` in `seq`][The sequence to search]]
- [[`f`][A unary function object][The search predicate]]
-]
-
-[heading Expression Semantics]
- __none__(seq, f);
-
-[*Return type]: `bool`
-
-[*Semantics]: Returns true if and only if `f(e)` evaluates to `false` for every element `e` in `seq`. Result equivalent to `!any(seq, f)`.
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/none.hpp>
-
-[heading Example]
- struct odd
- {
- template<typename T>
- bool operator()(T t) const
- {
- return t % 2;
- }
- };
- ...
- assert(__none__(__make_vector__(2,4), odd()));
- assert(!__none__(__make_vector__(1,2), odd()));
-
-[endsect]
-
-[section find]
-
-[heading Description]
-Finds the first element of a given type within a sequence.
-
-[heading Synopsis]
- template<
- typename T,
- typename Sequence
- >
- __unspecified__ find(Sequence const& seq);
-
- template<
- typename T,
- typename Sequence
- >
- __unspecified__ find(Sequence& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][The sequence to search]]
- [[`T`][Any type][The type to search for]]
-]
-
-[heading Expression Semantics]
- __find__<T>(seq)
-
-[*Return type]: A model of the same iterator category as the iterators of `seq`.
-
-[*Semantics]: Returns an iterator to the first element of `seq` of type `T`, or `__end__(seq)` if there is no such element.
-Equivalent to `__find_if__<boost::is_same<_, T> >(seq)`
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/find.hpp>
-
-[heading Example]
- const __vector__<char,int> vec('a','0');
- assert(*__find__<int>(vec) == '0');
- assert(__find__<double>(vec) == __end__(vec));
-
-[endsect]
-
-[section find_if]
-Finds the first element within a sequence with a type for which a given __mpl_lambda_expression__ evaluates to
-`boost::mpl::true_`.
-
-[heading Description]
-
-[heading Synopsis]
- template<
- typename F,
- typename Sequence
- >
- __unspecified__ find_if(Sequence const& seq);
-
- template<
- typename F,
- typename Sequence
- >
- __unspecified__ find_if(Sequence& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][The sequence to search]]
- [[`F`][A unary __mpl_lambda_expression__][The search predicate]]
-]
-
-[heading Expression Semantics]
- __find_if__<F>(seq)
-
-[*Return type]: An iterator of the same iterator category as the iterators of `seq`.
-
-[*Semantics]: Returns the first element of `seq` for which __mpl_lambda_expression__ `F` evaluates to `boost::mpl::true_`,
-or `__end__(seq)` if there is no such element.
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-
-/algorithm/query/find_if.hpp>
-
-[heading Example]
- const __vector__<double,int> vec(1.0,2);
- assert(*__find_if__<is_integral<mpl::_> >(vec) == 2);
- assert(__find_if__<is_class<mpl::_> >(vec) == __end__(vec));
-
-[endsect]
-
-[section count]
-
-[heading Description]
-Returns the number of elements of a given type within a sequence.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- typename __result_of_count__<Sequence, T>::type count(
- Sequence const& seq, T const& t);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `e == t` must be a valid expression, convertible to `bool`, for each element `e` in `seq`][The sequence to search]]
- [[`T`][Any type][The type to count]]
-]
-
-[heading Expression Semantics]
- __count__(seq, t);
-
-[*Return type]: `int`
-
-[*Semantics]: Returns the number of elements of type `T` and equal to `t` in `seq`.
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/count.hpp>
-
-[heading Example]
- const __vector__<double,int,int> vec(1.0,2,3);
- assert(__count__(vec,2) == 1);
-
-[endsect]
-
-[section count_if]
-
-[heading Description]
-Returns the number of elements within a sequence with a type for which a given unary function object evaluates to
-`true`.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- typename __result_of_count_if__<Sequence, F>::type count_if(
- Sequence const& seq, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `f(e)` is a valid expression, convertible to `bool`, for each element `e` in `seq`][The sequence to search]]
- [[`f`][A unary function object][The search predicate]]
-]
-
-[heading Expression Semantics]
- __count_if__(seq, f)
-
-[*Return type]: `int`
-
-[*Semantics]: Returns the number of elements in `seq` where `f` evaluates to `true`.
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/count_if.hpp>
-
-[heading Example]
- const __vector__<int,int,int> vec(1,2,3);
- assert(__count_if__(vec,odd()) == 2);
-
-[endsect]
-
-[endsect]
-
-[section Metafunctions]
-
-[section any]
-
-[heading Description]
-A metafunction returning the result type of __any__.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- struct any
- {
- typedef bool type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [Operation's argument]]
- [[`F`] [A model of unary __poly_func_obj__] [Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_any__<Sequence, F>::type
-
-[*Return type]: `bool`.
-
-[*Semantics]: Returns the return type of __any__ given a sequence of type `Sequence` and a unary __poly_func_obj__ of type `F`. The return type is always `bool`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/any.hpp>
-
-[endsect]
-
-[section all]
-
-[heading Description]
-A metafunction returning the result type of __all__.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- struct all
- {
- typedef bool type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [Operation's argument]]
- [[`F`] [A model of unary __poly_func_obj__] [Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_all__<Sequence, F>::type
-
-[*Return type]: `bool`.
-
-[*Semantics]: Returns the return type of __all__ given a sequence of type `Sequence` and a unary __poly_func_obj__ of type `F`. The return type is always `bool`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/all.hpp>
-
-[endsect]
-
-[section none]
-
-[heading Description]
-A metafunction returning the result type of __none__.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F
- >
- struct none
- {
- typedef bool type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [Operation's argument]]
- [[`F`] [A model of unary __poly_func_obj__] [Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_none__<Sequence, F>::type
-
-[*Return type]: `bool`.
-
-[*Semantics]: Returns the return type of __none__ given a sequence of type `Sequence` and a unary __poly_func_obj__ of type `F`. The return type is always `bool`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/none.hpp>
-
-[endsect]
-
-[section find]
-
-[heading Description]
-Returns the result type of `find`, given the sequence and search types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- struct find
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [Model of __forward_sequence__] [Operation's argument]]
- [[`T`] [Any type] [Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_find__<Sequence, T>::type
-
-[*Return type]: A model of the same iterator category as the iterators of `Sequence`.
-
-[*Semantics]: Returns an iterator to the first element of type `T` in `Sequence`, or `__result_of_end__<Sequence>::type` if there is no such element.
-
-[heading Complexity]
-Linear, at most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/find.hpp>
-
-[endsect]
-
-[section find_if]
-
-[heading Description]
-Returns the result type of `find_if` given the sequence and predicate types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename Pred
- >
- struct find_if
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [Operation's argument]]
- [[`Pred`] [A model of __mpl_lambda_expression__] [Operation's arguments]]
-]
-
-[heading Expression Semantics]
- __result_of_find_if__<Sequence, Pred>::type
-
-[*Return type]: A model of the same iterator category as the iterators of `Sequence`.
-
-[*Semantics]: Returns an iterator to the first element in `Sequence` for which `Pred` evaluates to true. Returns `__result_of_end__<Sequence>::type` if there is no such element.
-
-[heading Complexity]
-Linear. At most `__result_of_size__<Sequence>::value` comparisons.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/find_if.hpp>
-
-[endsect]
-
-[section count]
-
-[heading Description]
-A metafunction that returns the result type of `count` given the sequence and search types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- struct count
- {
- typedef int type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [heading Description]]
- [[`Sequence`] [A model of __forward_sequence__] [Operation's argument]]
- [[`T`] [Any type] [Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_count__<T>::type
-
-[*Return type]: `int`.
-
-[*Semantics]: Returns the return type of __count__. The return type is always `int`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/count.hpp>
-
-[endsect]
-
-[section count_if]
-
-[heading Description]
-A metafunction that returns the result type of `count_if` given the sequence and predicate types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename Pred
- >
- struct count_if
- {
- typedef int type;
- };
-
-[table Parameters
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A model of __forward_sequence__] [Operation's argument]]
- [[`Pred`] [A unary function object] [Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_count_if__<Sequence, Pred>::type
-
-[*Return type]: `int`.
-
-[*Semantics]: Returns the return type of __count_if__. The return type is always `int`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/query/count_if.hpp>
-
-[endsect]
-
-[endsect]
-
-[endsect]
-
-[section Transformation]
-The transformation algorithms create new sequences out of existing sequences by performing some sort of transformation. In reality the new sequences are views onto the data in the original sequences.
-
-[note As the transformation algorithms return views onto their input arguments,
-it is important that the lifetime of the input arguments is greater than the
-period during which you wish to use the results.]
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation.hpp>
-
-[section Functions]
-
-[section filter]
-
-[heading Description]
-For a given sequence, filter returns a new sequences containing only the elements of a specified type.
-
-[heading Synopsis]
- template<
- typename T,
- typename Sequence
- >
- typename __result_of_filter__<Sequence const, T>::type filter(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`T`][Any type][The type to retain]]
-]
-
-[heading Expression Semantics]
- __filter__<T>(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing all the elements of `seq` of type `T`.
-Equivalent to `__filter_if__<boost::same_type<_, T> >(seq)`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/filter.hpp>
-
-[heading Example]
- const __vector__<int,int,long,long> vec(1,2,3,4);
- assert(__filter__<int>(vec) == __make_vector__(1,2));
-
-[endsect]
-
-[section filter_if]
-
-[heading Description]
-For a given sequence, __filter_if__ returns a new sequences containing
-only the elements with types for which a given __mpl_lambda_expression__ evaluates to `boost::mpl::true_`.
-
-[heading Synopsis]
- template<
- typename Pred,
- typename Sequence
- >
- typename __result_of_filter_if__<Sequence const, Pred>::type filter_if(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`Pred`][A unary __mpl_lambda_expression__][The predicate to filter by]]
-]
-
-[heading Expression Semantics]
- __filter_if__<Pred>(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing all the elements of `seq` with types for which `Pred` evaluates
-to `boost::mpl::true_`. The order of the retained elements is the same as in the original sequence.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/filter_if.hpp>
-
-[heading Example]
- const __vector__<int,int,double,double> vec(1,2,3.0,4.0);
- assert(__filter_if__<is_integral<mpl::_> >(vec) == __make_vector__(1,2));
-
-[endsect]
-
-[section transform]
-
-[heading Description]
-For a sequence `seq` and function object or function pointer `f`, `transform` returns a new sequence
-with elements created by applying `f(e)` to each element of `e` of `seq`.
-
-[heading Unary version synopsis]
- template<
- typename Sequence,
- typename F
- >
- typename __result_of_transform__<Sequence const, F>::type transform(
- Sequence const& seq, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`f`][`f(e)` is a valid expression for each element `e` of `seq`. `__boost_result_of_call__<F(E)>::type` is the return type of `f` when called with a value of each element type `E`.][Transformation function]]
-]
-
-[heading Expression Semantics]
- __transform__(seq, f);
-
-[*Return type]: A model of __forward_sequence__
-
-[*Semantics]: Returns a new sequence, containing the return values of `f(e)` for each element `e` within `seq`.
-
-[heading Binary version synopsis]
- template<
- typename Sequence1,
- typename Sequence2,
- typename F
- >
- typename __result_of_transform__<Sequence1 const, Sequence2 const, F>::type transform(
- Sequence1 const& seq1, Sequence2 const& seq2, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq1`][A model of __forward_sequence__][Operation's argument]]
- [[`seq2`][A model of __forward_sequence__][Operation's argument]]
- [[`f`][`f(e1,e2)` is a valid expression for each pair of elements `e1` of `seq1` and `e2` of `seq2`. `__boost_result_of_call__<F(E1,E2)>::type` is the return type of `f` when called with elements of type `E1` and `E2`][Transformation function]]
-]
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing the return values of `f(e1, e2)` for each pair of elements `e1` and `e2` within `seq1` and `seq2` respectively.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/transform.hpp>
-
-[heading Example]
- struct triple
- {
- typedef int result_type;
-
- int operator()(int t) const
- {
- return t * 3;
- };
- };
- ...
- assert(__transform__(__make_vector__(1,2,3), triple()) == __make_vector__(3,6,9));
-
-[endsect]
-
-[section replace]
-
-[heading Description]
-Replaces each value within a sequence of a given type and value with a new value.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- typename __result_of_replace__<Sequence const, T>::type replace(
- Sequence const& seq, T const& old_value, T const& new_value);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__, `e == old_value` is a valid expression, convertible to `bool`, for each element `e` in `seq` with type convertible to `T`][Operation's argument]]
- [[`old_value`][Any type][Value to replace]]
- [[`new_value`][Any type][Replacement value]]
-]
-
-[heading Expression Semantics]
- __replace__(seq, old_value, new_value);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence with all the values of `seq` with `new_value` assigned to elements with the same type and equal to `old_value`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/replace.hpp>
-
-[heading Example]
- assert(__replace__(__make_vector__(1,2), 2, 3) == __make_vector__(1,3));
-
-[endsect]
-
-[section replace_if]
-
-[heading Description]
-Replaces each element of a given sequence for which an unary function object evaluates to `true` replaced with
-a new value.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F,
- typename T>
- typename __result_of_replace_if__<Sequence const, F, T>::type replace_if(
- Sequence const& seq, F f, T const& new_value);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`f`][A function object for which `f(e)` is a valid expression, convertible to `bool`, for each element `e` in `seq`][Operation's argument]]
- [[`new_value`][Any type][Replacement value]]
-]
-
-[heading Expression Semantics]
- __replace_if__(seq, f, new_value);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence with all the elements of `seq`,
-with `new_value` assigned to each element for which `f` evaluates to `true`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/replace_if.hpp>
-
-[heading Example]
- struct odd
- {
- template<typename T>
- bool operator()(T t) const
- {
- return t % 2;
- }
- };
- ...
- assert(__replace_if__(__make_vector__(1,2), odd(), 3) == __make_vector__(3,2));
-
-[endsect]
-
-[section remove]
-
-[heading Description]
-Returns a new sequence, with all the elements of the original sequence, except those of a given type.
-
-[heading Synopsis]
- template<
- typename T,
- typename Sequence
- >
- typename __result_of_remove__<Sequence const, T>::type replace(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`T`][Any type][Type to remove]]
-]
-
-[heading Expression Semantics]
- __remove__<T>(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq`, in their original order, except
-those of type `T`. Equivalent to `__remove_if__<boost::is_same<_,T> >(seq)`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/remove.hpp>
-
-[heading Example]
- const __vector__<int,double> vec(1,2.0);
- assert(__remove__<double>(vec) == __make_vector__(1));
-
-[endsect]
-
-[section remove_if]
-
-[heading Description]
-Returns a new sequence, containing all the elements of the original except those where a given unary
-function object evaluates to `true`.
-
-[heading Synopsis]
- template<
- typename Pred,
- typename Sequence
- >
- typename __result_of_remove_if__<Sequence const, Pred>::type remove_if(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`Pred`][A model of unary __mpl_lambda_expression__][Removal predicate]]
-]
-
-[heading Expression Semantics]
- __remove_if__<Pred>(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq`, in their original order, except
-those elements with types for which `Pred` evaluates to `boost::mpl::true_`.
-Equivalent to `__filter__<boost::mpl::not_<Pred> >(seq)`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/remove_if.hpp>
-
-[heading Example]
- const __vector__<int,double> vec(1,2.0);
- assert(__remove_if__<is_floating_point<mpl::_> >(vec) == __make_vector__(1));
-
-[endsect]
-
-[section reverse]
-
-[heading Description]
-Returns a new sequence with the elements of the original in reverse order.
-
-[heading Synposis]
- template<
- typename Sequence
- >
- typename __result_of_reverse__<Sequence const>::type reverse(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __bidirectional_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __reverse__(seq);
-
-[*Return type]: A model of __bidirectional_sequence__.
-
-[*Semantics]: Returns a new sequence containing all the elements of `seq` in reverse order.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/reverse.hpp>
-
-[heading Example]
- assert(__reverse__(__make_vector__(1,2,3)) == __make_vector__(3,2,1));
-
-[endsect]
-
-[section clear]
-
-[heading Description]
-__clear__ returns an empty sequence.
-
-[heading Synposis]
- template<
- typename Sequence
- >
- typename __result_of_clear__<Sequence const>::type clear(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __clear__(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Expression Semantics]: Returns a sequence with no elements.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/clear.hpp>
-
-[heading Example]
- assert(__clear__(__make_vector__(1,2,3)) == __make_vector__());
-
-[endsect]
-
-[section erase]
-
-[heading Description]
-Returns a new sequence, containing all the elements of the original except those at a specified iterator, or
-between two iterators.
-
-[heading Synposis]
- template<
- typename Sequence,
- typename First
- >
- typename __result_of_erase__<Sequence const, First>::type erase(
- Sequence const& seq, First const& it1);
-
- template<
- typename Sequence,
- typename First,
- typename Last
- >
- typename __result_of_erase__<Sequence const, First, Last>::type erase(
- Sequence const& seq, First const& it1, Last const& it2);
-
-[table Parameters
- [[Parameters][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`it1`][A model of __forward_iterator__][Iterator into `seq`]]
- [[`it2`][A model of __forward_iterator__][Iterator into `seq` after `it1`]]
-]
-
-[heading Expression Semantics]
- __erase__(seq, pos);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq` except the element at `pos`.
-
- __erase__(seq, first, last);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, with all the elements of `seq`, in their original order, except those
-in the range [`first`,`last`).
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/erase.hpp>
-
-[heading Example]
- const __vector__<int, double, char> vec(1, 2.0, 'c');
- assert(__erase__(vec, __next__(__begin__(vec))) == __make_vector__(1, 'c'));
- assert(__erase__(vec, __next__(__begin__(vec)), __end__(vec)) == __make_vector__(1));
-
-[endsect]
-
-[section erase_key]
-
-[heading Description]
-For an __associative_sequence__ `seq`, returns a __forward_sequence__ containing all the
-elements of the original except those with a given key.
-
-[heading Synposis]
- template<
- typename Key,
- typename Sequence
- >
- typename result_of::erase_key<Sequence const, Key>::type erase_key(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __associative_sequence__][Operation's argument]]
- [[`Key`][Any type][Key to erase]]
-]
-
-[heading Expression Semantics]
- __erase_key__<Key>(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq`, except those with key `Key`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/erase_key.hpp>
-
-[heading Example]
- assert(__erase_key__<int>(__make_map__<int, long>('a', 'b')) == __make_map__<long>('b'));
-
-[endsect]
-
-[section insert]
-
-[heading Description]
-Returns a new sequence with all the elements of the original, an a new element inserted the
-position described by a given iterator.
-
-[heading Synposis]
- template<
- typename Sequence,
- typename Pos,
- typename T
- >
- __unspecified__ insert(Sequence const& seq, Pos const& pos, T const& t);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`pos`][A model of __forward_iterator__][The position to insert at]]
- [[`t`][Any type][The value to insert]]
-]
-
-[heading Expression Semantics]
- __insert__(seq, p, t);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq`, in their original order, and a new element with the
-type and value of `t` inserted at iterator `pos`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/insert.hpp>
-
-[heading Example]
- const __vector__<int,int> vec(1,2);
- assert(__insert__(vec, __next__(__begin__(vec)), 3) == __make_vector__(1,3,2));
-
-[endsect]
-
-[section insert_range]
-
-[heading Description]
-Returns a new sequence with another sequence inserted at a specified iterator.
-
-[heading Synposis]
- template<
- typename Sequence,
- typename Pos,
- typename Range
- >
- typename __result_of_insert_range__<Sequence const, Pos, Range>::type insert_range(
- Sequence const& seq, Pos const& pos, Range const& range);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`pos`][A model of __forward_iterator__][The position to insert at]]
- [[`range`][A model of __forward_sequence__][Range to insert]]
-]
-
-[heading Expression Semantics]
- __insert__(seq, pos, range);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq`, and the elements of
-`range` inserted at iterator `pos`. All elements retaining their ordering from the orignal sequences.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/insert_range.hpp>
-
-[heading Example]
- const __vector__<int,int> vec(1,2);
- assert(__insert_range__(vec, __next__(__begin__(vec)), __make_vector__(3,4)) == __make_vector__(1,3,4,2));
-
-[endsect]
-
-[section join]
-
-[heading Description]
-Takes 2 sequences and returns a sequence containing the elements of the first followed by the elements of the second.
-
-[heading Synopsis]
- template<
- typename LhSequence,
- typename RhSequence>
- typename __result_of_join__<LhSequence, RhSequence>::type join(LhSequence const& lhs, RhSequence const& rhs);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`lhs`][A model of __forward_sequence__][Operation's argument]]
- [[`rhs`][A model of __forward_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __join__(lhs, rhs);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing all the elements of `lhs` followed by all the elements of `rhs`. The order of th elements is preserved.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/join.hpp>
-
-[heading Example]
- __vector__<int,char> v1(1, 'a');
- __vector__<int,char> v2(2, 'b');
- assert(__join__(v1, v2) == __make_vector__(1,'a',2,'b'));
-
-[endsect]
-
-[section zip]
-
-[heading Description]
-Zips sequences together to form a single sequence, whos members are tuples of the members of the component sequences.
-
-[heading Synopsis]
- template<
- typename Sequence1,
- typename Sequence2,
- ...
- typename SequenceN
- >
- typename __result_of_zip__<Sequence1, Sequence2, ... SequenceN>::type
- zip(Sequence1 const& seq1, Sequence2 const& seq2, ... SequenceN const& seqN);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq1` to `seqN`][Each sequence is a model of __forward_sequence__.][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __zip__(seq1, seq2, ... seqN);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing tuples of elements from sequences `seq1` to `seqN`. For example, applying zip to tuples `(1, 2, 3)` and `('a', 'b', 'c')` would return `((1, 'a'),(2, 'b'),(3, 'c'))`
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/zip.hpp>
-
-[heading Example]
- __vector__<int,char> v1(1, 'a');
- __vector__<int,char> v2(2, 'b');
- assert(__zip__(v1, v2) == __make_vector__(__make_vector__(1, 2),__make_vector__('a', 'b'));
-
-[endsect]
-
-[section pop_back]
-
-[heading Description]
-Returns a new sequence, with the last element of the original removed.
-
-[heading Synopsis]
- template<
- typename Sequence
- >
- typename __result_of_pop_back__<Sequence const>::type pop_back(Sequence const& seq);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __pop_back__(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence containing all the elements of `seq`, except the last element. The elements in the new sequence are in the same order as they were in `seq`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/pop_back.hpp>
-
-[heading Example]
- assert(___pop_back__(__make_vector__(1,2,3)) == __make_vector__(1,2));
-
-[endsect]
-
-[section pop_front]
-
-[heading Description]
-Returns a new sequence, with the first element of the original removed.
-
-[heading Synopsis]
- template<
- typename Sequence
- >
- typename __result_of_pop_front__<Sequence const>::type pop_front(Sequence const& seq);
-
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __pop_front__(seq);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence containing all the elements of `seq`, except the first element. The elements in the new sequence are in the same order as they were in `seq`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/pop_front.hpp>
-
-[heading Example]
- assert(__pop_front__(__make_vector__(1,2,3)) == __make_vector__(2,3));
-
-[endsect]
-
-[section push_back]
-
-[heading Description]
-Returns a new sequence with an element added at the end.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- typename __result_of_push_back__<Sequence, T>::type push_back(
- Sequence const& seq, T const& t);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`t`][Any type][The value to add to the end]]
-]
-
-[heading Expression Semantics]
- __push_back__(seq, t);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq`, and new element `t` appended to the end. The elements are in the same order as they were in `seq`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/push_back.hpp>
-
-[heading Example]
- assert(__push_back__(__make_vector__(1,2,3),4) == __make_vector__(1,2,3,4));
-
-[endsect]
-
-[section push_front]
-
-[heading Description]
-Returns a new sequence with an element added at the beginning.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- typename __result_of_push_front__<Sequence, T>::type push_front(
- Sequence const& seq, T const& t);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`t`][Any type][The value to add to the beginning]]
-]
-
-[heading Expression Semantics]
- __push_back__(seq, t);
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing all the elements of `seq`, and new element `t` appended to the beginning. The elements are in the same order as they were in `seq`.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/push_front.hpp>
-
-[heading Example]
- assert(__push_front__(__make_vector__(1,2,3),0) == __make_vector__(0,1,2,3));
-
-[endsect]
-
-[endsect]
-
-[section Metafunctions]
-
-[section filter]
-
-[heading Description]
-Returns the result type of __filter__ given the sequence type and type to retain.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- struct filter
- {
- typedef __unspecified__ type;
- };
-
-[table Parameter
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`][A model of __forward_sequence__] [Operation's argument]]
- [[`T`][Any type][Type to retain]]
-]
-
-[heading Expression Semantics]
- __result_of_filter__<Sequence, T>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing the elements of `Sequence` that are of type `T`. Equivalent to `__result_of_filter_if__<Sequence, boost::is_same<mpl::_, T> >::type`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/filter.hpp>
-
-[endsect]
-
-[section filter_if]
-
-[heading Description]
-Returns the result type of __filter_if__ given the sequence and unary __mpl_lambda_expression__ predicate type.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename Pred
- >
- struct filter_if
- {
- typedef __unspecified__ type;
- };
-
-[table Parameter
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`][A model of __forward_sequence__] [Operation's argument]]
- [[`Pred`][A unary __mpl_lambda_expression__][Type to retain]]
-]
-
-[heading Expression Semantics]
- __result_of_filter_if__<Sequence, Pred>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing the elements of `Sequence` for which `Pred` evaluates to `boost::mpl::true_`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/filter_if.hpp>
-
-[endsect]
-
-[section transform]
-
-[heading Description]
-For a sequence `seq` and function object or function pointer `f`, `transform` returns a new sequence
-with elements created by applying `f(e)` to each element of `e` of `seq`.
-
-[heading Unary version synopsis]
- template<
- typename Sequence,
- typename F
- >
- typename __result_of_transform__<Sequence const, F>::type transform(
- Sequence const& seq, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq`][A model of __forward_sequence__][Operation's argument]]
- [[`f`][`f(e)` is a valid expression for each element `e` of `seq`. `__boost_result_of_call__<F(E)>::type` is the return type of `f` when called with a value of each element type `E`.][Transformation function]]
-]
-
-[heading Expression Semantics]
- __transform__(seq, f);
-
-[*Return type]: A model of __forward_sequence__
-
-[*Semantics]: Returns a new sequence, containing the return values of `f(e)` for each element `e` within `seq`.
-
-[heading Binary version synopsis]
- template<
- typename Sequence1,
- typename Sequence2,
- typename F
- >
- typename __result_of_transform__<Sequence1 const, Sequence2 const, F>::type transform(
- Sequence1 const& seq1, Sequence2 const& seq2, F f);
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`seq1`][A model of __forward_sequence__][Operation's argument]]
- [[`seq2`][A model of __forward_sequence__][Operation's argument]]
- [[`f`][`f(e1,e2)` is a valid expression for each pair of elements `e1` of `seq1` and `e2` of `seq2`. `__boost_result_of_call__<F(E1,E2)>::type` is the return type of `f` when called with elements of type `E1` and `E2`][Transformation function]]
-]
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence, containing the return values of `f(e1, e2)` for each pair of elements `e1` and `e2` within `seq1` and `seq2` respectively.
-
-[heading Complexity]
-Constant. Returns a view which is lazily evaluated.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/transform.hpp>
-
-[heading Example]
- struct triple
- {
- typedef int result_type;
-
- int operator()(int t) const
- {
- return t * 3;
- };
- };
- ...
- assert(__transform__(__make_vector__(1,2,3), triple()) == __make_vector__(3,6,9));
-
-[endsect]
-
-[section replace]
-
-[heading Description]
-Returns the result type of __replace__, given the types of the input sequence and element to replace.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- struct replace
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`T`][Any type][The type of the search and replacement objects]]
-]
-
-[heading Expression Semantics]
- __result_of_replace__<Sequence,T>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns the return type of __replace__.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/replace.hpp>
-
-[endsect]
-
-[section replace_if]
-
-[heading Description]
-Returns the result type of __replace_if__, given the types of the sequence, __poly_func_obj__ predicate and replacement object.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename F,
- typename T>
- struct replace_if
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`F`][A model of unary __poly_func_obj__][Replacement predicate]]
- [[`T`][Any type][The type of the replacement object]]
-]
-
-[heading Expression Semantics]
- __result_of_replace_if__<Sequence,F,T>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns the return type of __replace_if__.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/replace_if.hpp>
-
-[endsect]
-
-[section remove]
-
-[heading Description]
-Returns the result type of __remove__, given the sequence and removal types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- struct remove
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`T`][Any type][Remove elements of this type]]
-]
-
-[heading Expression Semantics]
- __result_of_remove__<Sequence, T>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing the elements of `Sequence` not of type `T`. Equivalent to `__result_of_replace_if__<Sequence, boost::is_same<mpl::_, T> >::type`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/remove.hpp>
-
-[endsect]
-
-[section remove_if]
-
-[heading Description]
-Returns the result type of __remove_if__, given the input sequence and unary __mpl_lambda_expression__ predicate types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename Pred
- >
- struct remove_if
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`Pred`][A model of unary __mpl_lambda_expression__][Remove elements which evaluate to `boost::mpl::true_`]]
-]
-
-[heading Expression Semantics]
- __result_of_remove_if__<Sequence, Pred>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing the elements of `Sequence` for which `Pred` evaluates to `boost::mpl::false_`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/remove_if.hpp>
-
-[endsect]
-
-[section reverse]
-
-[heading Description]
-Returns the result type of __reverse__, given the input sequence type.
-
-[heading Synopsis]
- template<
- typename Sequence
- >
- struct reverse
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __bidirectional_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_reverse__<Sequence>::type
-
-[*Return type]: A model of __bidirectional_sequence__.
-
-[*Semantics]: Returns a sequence with the elements in the reverse order to `Sequence`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/reverse.hpp>
-
-[endsect]
-
-[section clear]
-
-[heading Description]
-Returns the result type of __clear__, given the input sequence type.
-
-[heading Synopsis]
- template<
- typename Sequence
- >
- struct clear
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][Any type][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_clear__<Sequence>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns an empty sequence.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/clear.hpp>
-
-[endsect]
-
-[section erase]
-Returns the result type of __erase__, given the input sequence and range delimiting iterator types.
-
-[heading Description]
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename It1,
- typename It2 = __unspecified__>
- struct erase
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`It1`][A model of __forward_iterator__][Operation's argument]]
- [[`It2`][A model of __forward_iterator__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_erase__<Sequence, It1>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence with the element at `It1` removed.
-
- __result_of_erase__<Sequence, It1, It2>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a new sequence with the elements between `It1` and `It2` removed.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/erase.hpp>
-
-[endsect]
-
-[section erase_key]
-
-[heading Description]
-Returns the result type of __erase_key__, given the sequence and key types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename Key
- >
- struct erase_key
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __associative_sequence__][Operation's argument]]
- [[`Key`][Any type][Key type]]
-]
-
-[heading Expression Semantics]
- __result_of_erase_key__<Sequence, Key>::type
-
-[*Return type]: A model of __associative_sequence__.
-
-[*Semantics]: Returns a sequence with the elements of `Sequence`, except those with key `Key`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/erase_key.hpp>
-
-[endsect]
-
-[section insert]
-
-[heading Description]
-Returns the result type of __insert__, given the sequence, position iterator and insertion types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename Position,
- typename T
- >
- struct insert
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`Position`][A model of __forward_iterator__][Operation's argument]]
- [[`T`][Any type][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_insert__<Sequence, Position, T>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence with an element of type `T` inserted at position `Position` in `Sequence`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/insert.hpp>
-
-[endsect]
-
-[section insert_range]
-
-[heading Description]
-Returns the result type of __insert_range__, given the input sequence, position iterator and insertion range types.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename Position,
- typename Range
- >
- struct insert_range
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`Position`][A model of __forward_iterator__][Operation's argument]]
- [[`Range`][A model of __forward_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_insert_range__<Sequence, Position, Range>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence with the elements of `Range` inserted at position `Position` into `Sequence`.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/insert_range.hpp>
-
-[endsect]
-
-[section join]
-
-[heading Description]
-Returns the result of joining 2 sequences, given the sequence types.
-
-[heading Synopsis]
- template<
- typename LhSequence,
- typename RhSequence
- >
- struct join
- {
- typedef __unspecified__ type;
- };
-
-[heading Expression Semantics]
- __result_of_join__<LhSequence, RhSequence>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence containing the elements of `LhSequence` followed by the elements of `RhSequence`. The order of the elements in the 2 sequences is preserved.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/join.hpp>
-
-[endsect]
-
-[section zip]
-
-[heading Description]
-Zips sequences together to form a single sequence, whos members are tuples of the members of the component sequences.
-
-[heading Synopsis]
- template<
- typename Sequence1,
- typename Sequence2,
- ...
- typename SequenceN
- >
- struct zip
- {
- typedef __unspecified__ type;
- };
-
-[heading Expression Semantics]
- __result_of_zip__<Sequence1, Sequence2, ... SequenceN>::type
-
-[*Return type]: A model of the most restrictive traversal category of sequences `Sequence1` to `SequenceN`.
-
-[*Semantics]: Return a sequence containing tuples of elements from each sequence. For example, applying zip to tuples `(1, 2, 3)` and `('a', 'b', 'c')` would return `((1, 'a'),(2, 'b'),(3, 'c'))`
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/transformation/zip.hpp>
-
-[endsect]
-
-[section pop_back]
-
-[heading Description]
-Returns the result type of __pop_back__, given the input sequence type.
-
-[heading Synopsis]
- template<
- typename Sequence
- >
- struct pop_back
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_pop_back__<Sequence>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence with all the elements of `Sequence` except the last element.
-
-[heading Complexity]
-Constant.
-
-[heading Header]
-
- #include <boost/fusion/algorithm/tranformation/pop_back.hpp>
-
-[endsect]
-
-[section pop_front]
-
-[heading Description]
-Returns the result type of __pop_front__, given the input sequence type.
-
-[heading Synopsis]
- template<
- typename Sequence
- >
- struct pop_front
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_pop_front__<Sequence>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence with all the elements of `Sequence` except the first element.
-
-[heading Complexity]
-Constant.
-
-/algorithm/transformation/pop_front.hpp>
-
-[endsect]
-
-[section push_back]
-
-[heading Description]
-Returns the result type of __push_back__, given the types of the input sequence and element to push.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- struct push_back
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`T`][Any type][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_push_back__<Sequence, T>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence with the elements of `Sequence` and an element of type `T` added to the end.
-
-[heading Complexity]
-Constant.
-
-/algorithm/transformation/push_back.hpp>
-
-[endsect]
-
-[section push_front]
-
-[heading Description]
-Returns the result type of __push_front__, given the types of the input sequence and element to push.
-
-[heading Synopsis]
- template<
- typename Sequence,
- typename T
- >
- struct push_front
- {
- typedef __unspecified__ type;
- };
-
-[table Parameters
- [[Parameter][Requirement][Description]]
- [[`Sequence`][A model of __forward_sequence__][Operation's argument]]
- [[`T`][Any type][Operation's argument]]
-]
-
-[heading Expression Semantics]
- __result_of_push_front__<Sequence, T>::type
-
-[*Return type]: A model of __forward_sequence__.
-
-[*Semantics]: Returns a sequence with the elements of `Sequence` and an element of type `T` added to the beginning.
-
-[heading Complexity]
-Constant.
-
-/algorithm/transformation/push_front.hpp>
-
-[endsect]
-
-[endsect]
-
-[endsect]
-
-[endsect]

Modified: trunk/libs/fusion/doc/container.qbk
==============================================================================
--- trunk/libs/fusion/doc/container.qbk (original)
+++ trunk/libs/fusion/doc/container.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -7,6 +7,7 @@
 [heading Header]
 
     #include <boost/fusion/container.hpp>
+ #include <boost/fusion/include/container.hpp>
 
 [section vector]
 
@@ -20,14 +21,21 @@
 [heading Header]
 
     #include <boost/fusion/container/vector.hpp>
+ #include <boost/fusion/include/vector.hpp>
     #include <boost/fusion/container/vector/vector_fwd.hpp>
+ #include <boost/fusion/include/vector_fwd.hpp>
 
     // numbered forms
     #include <boost/fusion/container/vector/vector10.hpp>
+ #include <boost/fusion/include/vector10.hpp>
     #include <boost/fusion/container/vector/vector20.hpp>
+ #include <boost/fusion/include/vector20.hpp>
     #include <boost/fusion/container/vector/vector30.hpp>
+ #include <boost/fusion/include/vector30.hpp>
     #include <boost/fusion/container/vector/vector40.hpp>
+ #include <boost/fusion/include/vector40.hpp>
     #include <boost/fusion/container/vector/vector50.hpp>
+ #include <boost/fusion/include/vector50.hpp>
 
 [heading Synopsis]
 
@@ -130,6 +138,7 @@
 [heading Header]
 
     #include <boost/fusion/container/list/cons.hpp>
+ #include <boost/fusion/include/cons.hpp>
 
 [heading Synopsis]
 
@@ -200,7 +209,9 @@
 [heading Header]
 
     #include <boost/fusion/container/list.hpp>
- #include <boost/fusion/container/list/list_forward.hpp>
+ #include <boost/fusion/include/list.hpp>
+ #include <boost/fusion/container/list/list_fwd.hpp>
+ #include <boost/fusion/include/list_fwd.hpp>
 
 [heading Synopsis]
 
@@ -284,6 +295,9 @@
 [heading Header]
 
     #include <boost/fusion/container/set.hpp>
+ #include <boost/fusion/include/set.hpp>
+ #include <boost/fusion/container/set_fwd.hpp>
+ #include <boost/fusion/include/set_fwd.hpp>
 
 [heading Synopsis]
 
@@ -363,6 +377,9 @@
 [heading Header]
 
     #include <boost/fusion/container/map.hpp>
+ #include <boost/fusion/include/map.hpp>
+ #include <boost/fusion/container/map_fwd.hpp>
+ #include <boost/fusion/include/map_fwd.hpp>
 
 [heading Synopsis]
 
@@ -434,4 +451,1198 @@
 
 [endsect]
 
+[section Generation]
+
+These are the functions that you can use to generate various forms of
+__containers__ from elemental values.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation.hpp>
+ #include <boost/fusion/include/generation.hpp>
+
+[section Functions]
+
+[section make_list]
+
+[heading Description]
+
+Create a __list__ from one or more values.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ typename __result_of_make_list__<T0, T1,... TN>::type
+ make_list(T0 const& x0, T1 const& x1... TN const& xN);
+
+The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
+`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
+to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
+before including any Fusion header to change the default. Example:
+
+ #define FUSION_MAX_LIST_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_list`]]
+]
+
+[heading Expression Semantics]
+
+ make_list(x0, x1,... xN);
+
+[*Return type]: __result_of_make_list__`<T0, T1,... TN>::type`
+
+[*Semantics]: Create a __list__ from `x0, x1,... xN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_list.hpp>
+ #include <boost/fusion/include/make_list.hpp>
+
+[heading Example]
+
+ make_list(123, "hello", 12.5)
+
+[heading See also]
+
+__note_boost_ref__
+
+[endsect]
+
+[section make_cons]
+
+[heading Description]
+
+Create a __cons__ from `car` (/head/) and optional `cdr` (/tail/).
+
+[heading Synopsis]
+
+ template <typename Car>
+ typename __result_of_make_cons__<Car>::type
+ make_cons(Car const& car);
+
+ template <typename Car, typename Cdr>
+ typename __result_of_make_cons__<Car, Cdr>::type
+ make_cons(Car const& car, Cdr const& cdr);
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`car`] [Instance of `Car`] [The list's head]]
+ [[`cdr`] [Instance of `Cdr`] [The list's tail (optional)]]
+]
+
+[heading Expression Semantics]
+
+ make_cons(car, cdr);
+
+[*Return type]: __result_of_make_cons__`<Car, Cdr>::type` or
+__result_of_make_cons__`<Car>::type`
+
+[*Semantics]: Create a __cons__ from `car` (/head/) and optional `cdr` (/tail/).
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_cons.hpp>
+ #include <boost/fusion/include/make_cons.hpp>
+
+[heading Example]
+
+ make_cons('x', make_cons(123))
+
+[heading See also]
+
+__note_boost_ref__
+
+[endsect]
+
+[section make_vector]
+
+[heading Description]
+
+Create a __vector__ from one or more values.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ typename __result_of_make_vector__<T0, T1,... TN>::type
+ make_vector(T0 const& x0, T1 const& x1... TN const& xN);
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
+where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
+defaults to `10`. You may define the preprocessor constant
+`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
+default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_vector`]]
+]
+
+[heading Expression Semantics]
+
+ make_vector(x0, x1,... xN);
+
+[*Return type]: __result_of_make_vector__`<T0, T1,... TN>::type`
+
+[*Semantics]: Create a __vector__ from `x0, x1,... xN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_vector.hpp>
+ #include <boost/fusion/include/make_vector.hpp>
+
+[heading Example]
+
+ make_vector(123, "hello", 12.5)
+
+[heading See also]
+
+__note_boost_ref__
+
+[endsect]
+
+[section make_set]
+
+[heading Description]
+
+Create a __set__ from one or more values.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ typename __result_of_make_set__<T0, T1,... TN>::type
+ make_set(T0 const& x0, T1 const& x1... TN const& xN);
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
+`set` is implemented in terms of the vector. That is why we reuse
+`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
+definable predefined maximum that defaults to `10`. You may define the
+preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
+header to change the default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_set`]]
+]
+
+[heading Expression Semantics]
+
+ make_set(x0, x1,... xN);
+
+[*Return type]: __result_of_make_set__`<T0, T1,... TN>::type`
+
+[*Semantics]: Create a __set__ from `x0, x1,... xN`.
+
+[*Precondition]: There may be no duplicate key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_set.hpp>
+ #include <boost/fusion/include/make_set.hpp>
+
+[heading Example]
+
+ make_set(123, "hello", 12.5)
+
+[heading See also]
+
+__note_boost_ref__
+
+[endsect]
+
+[section make_map]
+
+[heading Description]
+
+Create a __map__ from one or more key/data pairs.
+
+[heading Synopsis]
+
+ template <
+ typename K0, typename K1,... typename KN
+ , typename T0, typename T1,... typename TN>
+ typename __result_of_make_map__<K0, K0,... KN, T0, T1,... TN>::type
+ make_map(T0 const& x0, T1 const& x1... TN const& xN);
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
+`map` is implemented in terms of the vector. That is why we reuse
+`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
+definable predefined maximum that defaults to `10`. You may define the
+preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
+header to change the default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`K0, K1,... KN`] [The key types] [Keys associated with `x0, x1,... xN`]]
+ [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_map`]]
+]
+
+[heading Expression Semantics]
+
+ make_map<K0, K1,... KN>(x0, x1,... xN);
+
+[*Return type]: __result_of_make_map__`<K0, K0,... KN, T0, T1,... TN>::type`
+
+[*Semantics]: Create a __map__ from `K0, K1,... KN` keys and
+`x0, x1,... xN` data.
+
+[*Precondition]: There may be no duplicate key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_map.hpp>
+ #include <boost/fusion/include/make_map.hpp>
+
+[heading Example]
+
+ make_map(
+ __fusion_make_pair__<int>('X')
+ , __fusion_make_pair__<double>("Men"))
+
+[heading See also]
+
+__note_boost_ref__, __fusion_pair__
+
+[endsect]
+
+[section Tiers]
+
+Tiers are sequences, where all elements are non-const reference types. They
+are constructed with a call to a couple of /tie/ function templates. The
+succeeding sections document the various /tier/ flavors.
+
+* __list_tie__
+* __vector_tie__
+* __map_tie__
+
+Example:
+
+ int i; char c; double d;
+ ...
+ __vector_tie__(i, c, a);
+
+The __vector_tie__ function creates a __vector__ of type
+`__vector__<int&, char&, double&>`. The same result could be achieved with the call
+__make_vector__(__boost_ref_call__(i), __boost_ref_call__(c), __boost_ref_call__(a))
+[footnote see __boost_ref__ for details about `ref`].
+
+A /tie/ can be used to 'unpack' another tuple into variables. E.g.:
+
+ int i; char c; double d;
+ __vector_tie__(i, c, d) = __make_vector__(1,'a', 5.5);
+ std::cout << i << " " << c << " " << d;
+
+This code prints 1 a 5.5 to the standard output stream. A sequence
+unpacking operation like this is found for example in ML and Python. It is
+convenient when calling functions which return sequences.
+
+[heading Ignore]
+
+There is also an object called /ignore/ which allows you to ignore an
+element assigned by a sequence. The idea is that a function may return a
+sequence, only part of which you are interested in. For example:
+
+ char c;
+ __vector_tie__(ignore, c) = __make_vector__(1, 'a');
+
+[endsect]
+
+[section list_tie]
+
+[heading Description]
+
+Constructs a tie using a __list__ sequence.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ __list__<T0&, T1&,... TN&>
+ list_tie(T0& x0, T1& x1... TN& xN);
+
+The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
+`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
+to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
+before including any Fusion header to change the default. Example:
+
+ #define FUSION_MAX_LIST_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `list_tie`]]
+]
+
+[heading Expression Semantics]
+
+ list_tie(x0, x1,... xN);
+
+[*Return type]: __list__<T0&, T1&,... TN&>
+
+[*Semantics]: Create a __list__ of references from `x0, x1,... xN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/list_tie.hpp>
+ #include <boost/fusion/include/list_tie.hpp>
+
+[heading Example]
+
+ int i = 123;
+ double d = 123.456;
+ list_tie(i, d)
+
+[endsect]
+
+[section vector_tie]
+
+[heading Description]
+
+Constructs a tie using a __vector__ sequence.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ __vector__<T0&, T1&,... TN&>
+ vector_tie(T0& x0, T1& x1... TN& xN);
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
+where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
+defaults to `10`. You may define the preprocessor constant
+`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
+default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `vector_tie`]]
+]
+
+[heading Expression Semantics]
+
+ vector_tie(x0, x1,... xN);
+
+[*Return type]: __vector__<T0&, T1&,... TN&>
+
+[*Semantics]: Create a __vector__ of references from `x0, x1,... xN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/vector_tie.hpp>
+ #include <boost/fusion/include/vector_tie.hpp>
+
+[heading Example]
+
+ int i = 123;
+ double d = 123.456;
+ vector_tie(i, d)
+
+[endsect]
+
+[section map_tie]
+
+[heading Description]
+
+Constructs a tie using a __map__ sequence.
+
+[heading Synopsis]
+
+ template <typename K0, typename K1,... typename KN, typename D0, typename D1,... typename DN>
+ __map__<__pair__<K0, D0&>, __pair__<K1, D1&>,... __pair__<KN, DN&> >
+ map_tie(D0& d0, D1& d1... DN& dN);
+
+The variadic function accepts `0` to `FUSION_MAX_MAP_SIZE` elements,
+where `FUSION_MAX_MAP_SIZE` is a user definable predefined maximum that
+defaults to `10`, and a corresponding number of key types.
+You may define the preprocessor constant `FUSION_MAX_MAP_SIZE` before
+including any Fusion header to change the default. Example:
+
+ #define FUSION_MAX_MAP_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`K0, K1,... KN`] [Any type][The key types associated with each of the `x1,x2,...,xN` values]]
+ [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `map_tie`]]
+]
+
+[heading Expression Semantics]
+
+ map_tie<K0, K1,... KN>(x0, x1,... xN);
+
+[*Return type]: __map__<__pair__<K0, D0&>, __pair__<K1, D1&>,... __pair__<KN, DN&> >
+
+[*Semantics]: Create a __map__ of references from `x0, x1,... xN` with keys `K0, K1,... KN`
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/map_tie.hpp>
+ #include <boost/fusion/include/map_tie.hpp>
+
+[heading Example]
+
+ struct int_key;
+ struct double_key;
+ ...
+ int i = 123;
+ double d = 123.456;
+ map_tie<int_key, double_key>(i, d)
+
+[endsect]
+
+[endsect]
+
+[section MetaFunctions]
+
+[section make_list]
+
+[heading Description]
+
+Returns the result type of __make_list__.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ struct make_list;
+
+The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
+`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
+to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
+before including any Fusion header to change the default. Example:
+
+ #define FUSION_MAX_LIST_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`T0, T1,... TN`] [Any type] [Template arguments to `make_list`]]
+]
+
+[heading Expression Semantics]
+
+ result_of::make_list<T0, T1,... TN>::type
+
+[*Return type]: A __list__ with elements of types converted following the
+rules for __element_conversion__.
+
+[*Semantics]: Create a __list__ from `T0, T1,... TN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_list.hpp>
+ #include <boost/fusion/include/make_list.hpp>
+
+[heading Example]
+
+ result_of::make_list<int, const char(&)[7], double>::type
+
+[endsect]
+
+[section make_cons]
+
+[heading Description]
+
+Returns the result type of __make_cons__.
+
+[heading Synopsis]
+
+ template <typename Car, typename Cdr = nil>
+ struct make_cons;
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`Car`] [Any type] [The list's head type]]
+ [[`Cdr`] [A `cons`] [The list's tail type (optional)]]
+]
+
+[heading Expression Semantics]
+
+ result_of::make_cons<Car, Cdr>::type
+
+[*Return type]: A __cons__ with head element, `Car`, of type converted
+following the rules for __element_conversion__, and tail, `Cdr`.
+
+[*Semantics]: Create a __cons__ from `Car` (/head/) and optional `Cdr` (/tail/).
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_cons.hpp>
+ #include <boost/fusion/include/make_cons.hpp>
+
+[heading Example]
+
+ result_of::make_cons<char, result_of::make_cons<int>::type>::type
+
+[endsect]
+
+[section make_vector]
+
+[heading Description]
+
+Returns the result type of __make_vector__.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ struct make_vector;
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
+where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
+defaults to `10`. You may define the preprocessor constant
+`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
+default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`T0, T1,... TN`] [Any type] [Template arguments to `make_vector`]]
+]
+
+[heading Expression Semantics]
+
+ result_of::make_vector<T0, T1,... TN>::type
+
+[*Return type]: A __vector__ with elements of types converted following the
+rules for __element_conversion__.
+
+[*Semantics]: Create a __vector__ from `T0, T1,... TN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_list.hpp>
+ #include <boost/fusion/include/make_list.hpp>
+
+[heading Example]
+
+ result_of::make_vector<int, const char(&)[7], double>::type
+
+[endsect]
+
+[section make_set]
+
+[heading Description]
+
+Returns the result type of __make_set__.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ struct make_set;
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
+`set` is implemented in terms of the vector. That is why we reuse
+`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
+definable predefined maximum that defaults to `10`. You may define the
+preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
+header to change the default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`T0, T1,... TN`] [Any type] [The arguments to `make_set`]]
+]
+
+[heading Expression Semantics]
+
+ result_of::make_set<T0, T1,... TN>::type
+
+[*Return type]: A __set__ with elements of types converted following the
+rules for __element_conversion__.
+
+[*Semantics]: Create a __set__ from `T0, T1,... TN`.
+
+[*Precondition]: There may be no duplicate key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_set.hpp>
+ #include <boost/fusion/include/make_set.hpp>
+
+[heading Example]
+
+ result_of::make_set<int, char, double>::type
+
+[endsect]
+
+[section make_map]
+
+[heading Description]
+
+Returns the result type of __make_map__.
+
+[heading Synopsis]
+
+ template <
+ typename K0, typename K1,... typename KN
+ , typename T0, typename T1,... typename TN>
+ struct make_map;
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
+`map` is implemented in terms of the vector. That is why we reuse
+`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
+definable predefined maximum that defaults to `10`. You may define the
+preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
+header to change the default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`K0, K1,... KN`] [Any type] [Keys associated with `T0, T1,... TN`]]
+ [[`T0, T1,... TN`] [Any type] [Data associated with keys `K0, K1,... KN`]]
+]
+
+[heading Expression Semantics]
+
+ resulf_of::make_map<K0, K1,... KN, T0, T1,... TN>::type;
+
+[*Return type]: __result_of_make_map__`<K0, K0,... KN, T0, T1,... TN>::type`
+
+[*Semantics]: A __map__ with __fusion_pair__ elements where the
+`second_type` is converted following the rules for __element_conversion__.
+
+[*Precondition]: There may be no duplicate key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/make_map.hpp>
+ #include <boost/fusion/include/make_map.hpp>
+
+[heading Example]
+
+ result_of::make_map<int, double, char, double>::type
+
+[heading See also]
+
+__fusion_pair__
+
+[endsect]
+
+[section list_tie]
+
+[heading Description]
+
+Returns the result type of __list_tie__.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ struct list_tie;
+
+The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
+`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
+to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
+before including any Fusion header to change the default. Example:
+
+ #define FUSION_MAX_LIST_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`T0, T1,... TN`] [Any type] [The arguments to `list_tie`]]
+]
+
+[heading Expression Semantics]
+
+ result_of::list_tie<T0, T1,... TN>::type;
+
+[*Return type]: __list__<T0&, T1&,... TN&>
+
+[*Semantics]: Create a __list__ of references from `T0, T1,... TN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/list_tie.hpp>
+ #include <boost/fusion/include/list_tie.hpp>
+
+[heading Example]
+
+ result_of::list_tie<int, double>::type
+
+[endsect]
+
+[section vector_tie]
+
+[heading Description]
+
+Returns the result type of __vector_tie__.
+
+[heading Synopsis]
+
+ template <typename T0, typename T1,... typename TN>
+ struct vector_tie;
+
+The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
+where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
+defaults to `10`. You may define the preprocessor constant
+`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
+default. Example:
+
+ #define FUSION_MAX_VECTOR_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`T0, T1,... TN`] [Any type] [The arguments to `vector_tie`]]
+]
+
+[heading Expression Semantics]
+
+ result_of::vector_tie<T0, T1,... TN>::type;
+
+[*Return type]: __vector__<T0&, T1&,... TN&>
+
+[*Semantics]: Create a __vector__ of references from `T0, T1,... TN`.
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/vector_tie.hpp>
+ #include <boost/fusion/include/vector_tie.hpp>
+
+[heading Example]
+
+ result_of::vector_tie<int, double>::type
+
+[endsect]
+
+[section map_tie]
+
+[heading Description]
+
+Returns the result type of __map_tie__.
+
+[heading Synopsis]
+
+ template <typename K0, typename K1,... typename KN, typename D0, typename D1,... typename DN>
+ struct map_tie;
+
+The variadic function accepts `0` to `FUSION_MAX_MAP_SIZE` elements,
+where `FUSION_MAX_MAP_SIZE` is a user definable predefined maximum that
+defaults to `10`. You may define the preprocessor constant
+`FUSION_MAX_MAP_SIZE` before including any Fusion header to change the
+default. Example:
+
+ #define FUSION_MAX_MAP_SIZE 20
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`K0, K1,... KN`] [Any type] [The key types for `map_tie`]]
+ [[`D0, D1,... DN`] [Any type] [The arguments types for `map_tie`]]
+]
+
+[heading Expression Semantics]
+
+ result_of::map_tie<K0, K1,... KN, D0, D1,... DN>::type;
+
+[*Return type]: __map__<__pair__<K0, D0&>, __pair__<K1, D1&>,... __pair__<KN, DN&> >
+
+[*Semantics]: Create a __map__ of references from `D0, D1,... DN` with keys `K0, K1,... KN`
+
+[heading Header]
+
+ #include <boost/fusion/container/generation/map_tie.hpp>
+ #include <boost/fusion/include/map_tie.hpp>
+
+[heading Example]
+
+ struct int_key;
+ struct double_key;
+ ...
+ result_of::map_tie<int_key, double_key, int, double>::type
+
+[endsect]
+
+[endsect]
+
+[endsect]
+
+[section Conversion]
+
+All fusion sequences can be converted to one of the __containers__ types
+using one of these conversion functions.
+
+[heading Header]
+
+ #include <boost/fusion/include/convert.hpp>
+
+[section Functions]
+
+[section as_list]
+
+[heading Description]
+
+Convert a fusion sequence to a __list__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ typename result_of::as_list<Sequence>::type
+ as_list(Sequence& seq);
+
+ template <typename Sequence>
+ typename result_of::as_list<Sequence const>::type
+ as_list(Sequence const& seq);
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`seq`] [An instance of Sequence] [The sequence to convert.]]
+]
+
+[heading Expression Semantics]
+
+ as_list(seq);
+
+[*Return type]: __result_of_as_list__`<Sequence>::type`
+
+[*Semantics]: Convert a fusion sequence, `seq`, to a __list__.
+
+[heading Header]
+
+ #include <boost/fusion/container/list/convert.hpp>
+ #include <boost/fusion/include/as_list.hpp>
+
+[heading Example]
+
+ as_list(__make_vector__('x', 123, "hello"))
+
+[endsect]
+
+[section as_vector]
+
+[heading Description]
+
+Convert a fusion sequence to a __vector__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ typename result_of::as_vector<Sequence>::type
+ as_vector(Sequence& seq);
+
+ template <typename Sequence>
+ typename result_of::as_vector<Sequence const>::type
+ as_vector(Sequence const& seq);
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`seq`] [An instance of Sequence] [The sequence to convert.]]
+]
+
+[heading Expression Semantics]
+
+ as_vector(seq);
+
+[*Return type]: __result_of_as_vector__`<Sequence>::type`
+
+[*Semantics]: Convert a fusion sequence, `seq`, to a __vector__.
+
+[heading Header]
+
+ #include <boost/fusion/container/vector/convert.hpp>
+ #include <boost/fusion/include/as_vector.hpp>
+
+[heading Example]
+
+ as_vector(__make_list__('x', 123, "hello"))
+
+[endsect]
+
+[section as_set]
+
+[heading Description]
+
+Convert a fusion sequence to a __set__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ typename result_of::as_set<Sequence>::type
+ as_set(Sequence& seq);
+
+ template <typename Sequence>
+ typename result_of::as_set<Sequence const>::type
+ as_set(Sequence const& seq);
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`seq`] [An instance of Sequence] [The sequence to convert.]]
+]
+
+[heading Expression Semantics]
+
+ as_set(seq);
+
+[*Return type]: __result_of_as_set__`<Sequence>::type`
+
+[*Semantics]: Convert a fusion sequence, `seq`, to a __set__.
+
+[*Precondition]: There may be no duplicate key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/set/convert.hpp>
+ #include <boost/fusion/include/as_set.hpp>
+
+[heading Example]
+
+ as_set(__make_vector__('x', 123, "hello"))
+
+[endsect]
+
+[section as_map]
+
+[heading Description]
+
+Convert a fusion sequence to a __map__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ typename result_of::as_map<Sequence>::type
+ as_map(Sequence& seq);
+
+ template <typename Sequence>
+ typename result_of::as_map<Sequence const>::type
+ as_map(Sequence const& seq);
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`seq`] [An instance of Sequence] [The sequence to convert.]]
+]
+
+[heading Expression Semantics]
+
+ as_map(seq);
+
+[*Return type]: __result_of_as_map__`<Sequence>::type`
+
+[*Semantics]: Convert a fusion sequence, `seq`, to a __map__.
+
+[*Precondition]: The elements of the sequence are assumed to be
+__fusion_pair__s. There may be no duplicate __fusion_pair__ key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/map/convert.hpp>
+ #include <boost/fusion/include/as_map.hpp>
+
+[heading Example]
+
+ as_map(__make_vector__(
+ __fusion_make_pair__<int>('X')
+ , __fusion_make_pair__<double>("Men")))
+
+[endsect]
+
+[endsect]
+
+[section Metafunctions]
+
+[section as_list]
+
+[heading Description]
+
+Returns the result type of __as_list__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ struct as_list;
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`Sequence`] [A fusion __sequence__] [The sequence type to convert.]]
+]
+
+[heading Expression Semantics]
+
+ result_of::as_list<Sequence>::type;
+
+[*Return type]: A __list__ with same elements as the input sequence,
+`Sequence`.
+
+[*Semantics]: Convert a fusion sequence, `Sequence`, to a __list__.
+
+[heading Header]
+
+ #include <boost/fusion/container/list/convert.hpp>
+ #include <boost/fusion/include/as_list.hpp>
+
+[heading Example]
+
+ result_of::as_list<__vector__<char, int> >::type
+
+[endsect]
+
+[section as_vector]
+
+[heading Description]
+
+Returns the result type of __as_vector__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ struct as_vector;
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`Sequence`] [A fusion __sequence__] [The sequence to convert.]]
+]
+
+[heading Expression Semantics]
+
+ result_of::as_vector<Sequence>::type;
+
+[*Return type]: A __vector__ with same elements as the input sequence,
+`Sequence`.
+
+[*Semantics]: Convert a fusion sequence, `Sequence`, to a __vector__.
+
+[heading Header]
+
+ #include <boost/fusion/container/vector/convert.hpp>
+ #include <boost/fusion/include/as_vector.hpp>
+
+[heading Example]
+
+ result_of::as_vector<__list__<char, int> >::type
+
+[endsect]
+
+[section as_set]
+
+[heading Description]
+
+Returns the result type of __as_set__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ struct as_set;
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`Sequence`] [A fusion __sequence__] [The sequence to convert.]]
+]
+
+[heading Expression Semantics]
+
+ result_of::as_set<Sequence>::type;
+
+[*Return type]: A __set__ with same elements as the input sequence,
+`Sequence`.
+
+[*Semantics]: Convert a fusion sequence, `Sequence`, to a __set__.
+
+[*Precondition]: There may be no duplicate key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/set/convert.hpp>
+ #include <boost/fusion/include/as_set.hpp>
+
+[heading Example]
+
+ result_of::as_set<__vector__<char, int> >::type
+
+[endsect]
+
+[section as_map]
+
+[heading Description]
+
+Returns the result type of __as_map__.
+
+[heading Synopsis]
+
+ template <typename Sequence>
+ struct as_map;
+
+[heading Parameters]
+
+[table
+ [[Parameter] [Requirement] [Description]]
+ [[`Sequence`] [A fusion __sequence__] [The sequence to convert.]]
+]
+
+[heading Expression Semantics]
+
+ result_of::as_map<Sequence>::type;
+
+[*Return type]: A __map__ with same elements as the input sequence,
+`Sequence`.
+
+[*Semantics]: Convert a fusion sequence, `Sequence`, to a __map__.
+
+[*Precondition]: The elements of the sequence are assumed to be
+__fusion_pair__s. There may be no duplicate __fusion_pair__ key types.
+
+[heading Header]
+
+ #include <boost/fusion/container/map/convert.hpp>
+ #include <boost/fusion/include/as_map.hpp>
+
+[heading Example]
+
+ result_of::as_map<__vector__<
+ __fusion_pair__<int, char>
+ , __fusion_pair__<double, std::string> > >::type
+
+[endsect]
+
+[endsect]
+
+[endsect]
+
 [endsect]

Modified: trunk/libs/fusion/doc/extension.qbk
==============================================================================
--- trunk/libs/fusion/doc/extension.qbk (original)
+++ trunk/libs/fusion/doc/extension.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -52,6 +52,7 @@
 `traits::tag_of` for our sequence type.
 
     #include <boost/fusion/support/tag_of_fwd.hpp>
+ #include <boost/fusion/include/tag_of_fwd.hpp>
 
     namespace boost { namespace fusion { namespace traits {
         template<>
@@ -67,6 +68,7 @@
 for our sequence, but for an example see the code in:
 
     #include <boost/fusion/adapted/array/tag_of.hpp>
+ #include <boost/fusion/include/tag_of.hpp>
 
 [heading Designing a suitable iterator]
 
@@ -457,6 +459,7 @@
 [heading Header]
 
     #include <boost/fusion/iterator/iterator_facade.hpp>
+ #include <boost/fusion/include/iterator_facade.hpp>
 
 [endsect]
 

Modified: trunk/libs/fusion/doc/functional.qbk
==============================================================================
--- trunk/libs/fusion/doc/functional.qbk (original)
+++ trunk/libs/fusion/doc/functional.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -1220,6 +1220,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_fused.hpp>
+ #include <boost/fusion/include/make_fused.hpp>
 
 [heading Example]
     float sub(float a, float b) { return a - b; }
@@ -1268,6 +1269,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_fused_procedure.hpp>
+ #include <boost/fusion/include/make_fused_procedure.hpp>
 
 [heading Example]
     __vector__<int,int,int> v(1,2,3);
@@ -1310,6 +1312,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_fused_function_object.hpp>
+ #include <boost/fusion/include/make_fused_function_object.hpp>
 
 [heading Example]
     struct sub
@@ -1371,6 +1374,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_unfused_generic.hpp>
+ #include <boost/fusion/include/make_unfused_generic.hpp>
 
 [heading Example]
     struct bottles_song
@@ -1439,6 +1443,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_unfused_lvalue_args.hpp>
+ #include <boost/fusion/include/make_unfused_lvalue_args.hpp>
 
 [heading Example]
     struct fused_incrementer
@@ -1498,6 +1503,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_unfused_rvalue_args.hpp>
+ #include <boost/fusion/include/make_unfused_rvalue_args.hpp>
 
 [heading Example]
     struct sequence_printer
@@ -1540,6 +1546,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_fused.hpp>
+ #include <boost/fusion/include/make_fused.hpp>
 
 [heading Synopsis]
     namespace result_of
@@ -1564,6 +1571,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_fused_procedure.hpp>
+ #include <boost/fusion/include/make_fused_procedure.hpp>
 
 [heading Synopsis]
     namespace result_of
@@ -1588,6 +1596,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_fused_function_object.hpp>
+ #include <boost/fusion/include/make_fused_function_object.hpp>
 
 [heading Synopsis]
     namespace result_of
@@ -1612,6 +1621,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_unfused_generic.hpp>
+ #include <boost/fusion/include/make_unfused_generic.hpp>
 
 [heading Synopsis]
     namespace result_of
@@ -1636,6 +1646,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_unfused_lvalue_args.hpp>
+ #include <boost/fusion/include/make_unfused_lvalue_args.hpp>
 
 [heading Synopsis]
     namespace result_of
@@ -1660,6 +1671,7 @@
 [heading Header]
 
     #include <boost/fusion/functional/generation/make_unfused_rvalue_args.hpp>
+ #include <boost/fusion/include/make_unfused_rvalue_args.hpp>
 
 [heading Synopsis]
     namespace result_of

Modified: trunk/libs/fusion/doc/fusion.qbk
==============================================================================
--- trunk/libs/fusion/doc/fusion.qbk (original)
+++ trunk/libs/fusion/doc/fusion.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -145,36 +145,36 @@
 [def __result_of_value_at_c__ [link fusion.sequence.intrinsic.metafunctions.value_at_c `result_of::value_at_c`]]
 [def __result_of_value_at_key__ [link fusion.sequence.intrinsic.metafunctions.value_at_key `result_of::value_at_key`]]
 
-[def __conversion__ [link fusion.sequence.conversion.functions Conversion]]
-[def __result_of_conversion__ [link fusion.sequence.conversion.metafunctions Conversion Metafunctions]]
-[def __as_vector__ [link fusion.sequence.conversion.functions.as_vector `as_vector`]]
-[def __result_of_as_vector__ [link fusion.sequence.conversion.metafunctions.as_vector `result_of::as_vector`]]
-[def __as_list__ [link fusion.sequence.conversion.functions.as_list `as_list`]]
-[def __result_of_as_list__ [link fusion.sequence.conversion.metafunctions.as_list `result_of::as_list`]]
-[def __as_set__ [link fusion.sequence.conversion.functions.as_set `as_set`]]
-[def __result_of_as_set__ [link fusion.sequence.conversion.metafunctions.as_set `result_of::as_set`]]
-[def __as_map__ [link fusion.sequence.conversion.functions.as_map `as_map`]]
-[def __result_of_as_map__ [link fusion.sequence.conversion.metafunctions.as_map `result_of::as_map`]]
-
-[def __generation__ [link fusion.sequence.generation.functions Generation]]
-[def __result_of_generation__ [link fusion.sequence.generation.metafunctions Generation Metafunctions]]
-[def __make_vector__ [link fusion.sequence.generation.functions.make_vector `make_vector`]]
-[def __result_of_make_vector__ [link fusion.sequence.generation.metafunctions.make_vector `result_of::make_vector`]]
-[def __vector_tie__ [link fusion.sequence.generation.functions.vector_tie `vector_tie`]]
-[def __map_tie__ [link fusion.sequence.generation.functions.vector_tie `map_tie`]]
-[def __result_of_vector_tie__ [link fusion.sequence.generation.metafunctions.vector_tie `result_of::vector_tie`]]
-[def __make_vector__ [link fusion.sequence.generation.functions.make_vector `make_vector`]]
-[def __result_of_make_vector__ [link fusion.sequence.generation.metafunctions.make_vector `result_of::make_vector`]]
-[def __make_cons__ [link fusion.sequence.generation.functions.make_cons `make_cons`]]
-[def __result_of_make_cons__ [link fusion.sequence.generation.metafunctions.make_cons `result_of::make_cons`]]
-[def __make_list__ [link fusion.sequence.generation.functions.make_list `make_list`]]
-[def __result_of_make_list__ [link fusion.sequence.generation.metafunctions.make_list `result_of::make_list`]]
-[def __make_set__ [link fusion.sequence.generation.functions.make_set `make_set`]]
-[def __result_of_make_set__ [link fusion.sequence.generation.metafunctions.make_set `result_of::make_set`]]
-[def __make_map__ [link fusion.sequence.generation.functions.make_map `make_map`]]
-[def __result_of_make_map__ [link fusion.sequence.generation.metafunctions.make_map `result_of::make_map`]]
-[def __list_tie__ [link fusion.sequence.generation.functions.list_tie `list_tie`]]
-[def __result_of_list_tie__ [link fusion.sequence.generation.metafunctions.list_tie `result_of::list_tie`]]
+[def __conversion__ [link fusion.container.conversion.functions Conversion]]
+[def __result_of_conversion__ [link fusion.container.conversion.metafunctions Conversion Metafunctions]]
+[def __as_vector__ [link fusion.container.conversion.functions.as_vector `as_vector`]]
+[def __result_of_as_vector__ [link fusion.container.conversion.metafunctions.as_vector `result_of::as_vector`]]
+[def __as_list__ [link fusion.container.conversion.functions.as_list `as_list`]]
+[def __result_of_as_list__ [link fusion.container.conversion.metafunctions.as_list `result_of::as_list`]]
+[def __as_set__ [link fusion.container.conversion.functions.as_set `as_set`]]
+[def __result_of_as_set__ [link fusion.container.conversion.metafunctions.as_set `result_of::as_set`]]
+[def __as_map__ [link fusion.container.conversion.functions.as_map `as_map`]]
+[def __result_of_as_map__ [link fusion.container.conversion.metafunctions.as_map `result_of::as_map`]]
+
+[def __generation__ [link fusion.container.generation.functions Generation]]
+[def __result_of_generation__ [link fusion.container.generation.metafunctions Generation Metafunctions]]
+[def __make_vector__ [link fusion.container.generation.functions.make_vector `make_vector`]]
+[def __result_of_make_vector__ [link fusion.container.generation.metafunctions.make_vector `result_of::make_vector`]]
+[def __vector_tie__ [link fusion.container.generation.functions.vector_tie `vector_tie`]]
+[def __map_tie__ [link fusion.container.generation.functions.vector_tie `map_tie`]]
+[def __result_of_vector_tie__ [link fusion.container.generation.metafunctions.vector_tie `result_of::vector_tie`]]
+[def __make_vector__ [link fusion.container.generation.functions.make_vector `make_vector`]]
+[def __result_of_make_vector__ [link fusion.container.generation.metafunctions.make_vector `result_of::make_vector`]]
+[def __make_cons__ [link fusion.container.generation.functions.make_cons `make_cons`]]
+[def __result_of_make_cons__ [link fusion.container.generation.metafunctions.make_cons `result_of::make_cons`]]
+[def __make_list__ [link fusion.container.generation.functions.make_list `make_list`]]
+[def __result_of_make_list__ [link fusion.container.generation.metafunctions.make_list `result_of::make_list`]]
+[def __make_set__ [link fusion.container.generation.functions.make_set `make_set`]]
+[def __result_of_make_set__ [link fusion.container.generation.metafunctions.make_set `result_of::make_set`]]
+[def __make_map__ [link fusion.container.generation.functions.make_map `make_map`]]
+[def __result_of_make_map__ [link fusion.container.generation.metafunctions.make_map `result_of::make_map`]]
+[def __list_tie__ [link fusion.container.generation.functions.list_tie `list_tie`]]
+[def __result_of_list_tie__ [link fusion.container.generation.metafunctions.list_tie `result_of::list_tie`]]
 
 [def __out__ [link fusion.sequence.operator.i_o.out out]]
 [def __in__ [link fusion.sequence.operator.i_o.in in]]
@@ -185,66 +185,66 @@
 [def __gt__ [link fusion.sequence.operator.comparison.greater_than greater than]]
 [def __gte__ [link fusion.sequence.operator.comparison.greater_than_equal greater than equal]]
 
-[def __algorithm__ [link fusion.algorithms Algorithm]]
-[def __algorithms__ [link fusion.algorithms Algorithms]]
-[def __fold__ [link fusion.algorithms.iteration.functions.fold `fold`]]
-[def __result_of_fold__ [link fusion.algorithms.iteration.metafunctions.fold `result_of::fold`]]
-[def __accumulate__ [link fusion.algorithms.iteration.functions.accumulate `accumulate`]]
-[def __result_of_accumulate__ [link fusion.algorithms.iteration.metafunctions.accumulate `result_of::accumulate`]]
-[def __for_each__ [link fusion.algorithms.iteration.functions.for_each `for_each`]]
-[def __result_of_for_each__ [link fusion.algorithms.iteration.metafunctions.for_each `result_of::for_each`]]
-[def __any__ [link fusion.algorithms.query.functions.any `any`]]
-[def __result_of_any__ [link fusion.algorithms.query.metafunctions.any `result_of::any`]]
-[def __all__ [link fusion.algorithms.query.functions.all `all`]]
-[def __result_of_all__ [link fusion.algorithms.query.metafunctions.all `result_of::all`]]
-[def __none__ [link fusion.algorithms.query.functions.none `none`]]
-[def __result_of_none__ [link fusion.algorithms.query.metafunctions.none `result_of::none`]]
-[def __find__ [link fusion.algorithms.query.functions.find `find`]]
-[def __result_of_find__ [link fusion.algorithms.query.metafunctions.find `result_of::find`]]
-[def __find_if__ [link fusion.algorithms.query.functions.find_if `find_if`]]
-[def __result_of_find_if__ [link fusion.algorithms.query.metafunctions.find_if `result_of::find_if`]]
-[def __count__ [link fusion.algorithms.query.functions.count `count`]]
-[def __result_of_count__ [link fusion.algorithms.query.metafunctions.count `result_of::count`]]
-[def __count_if__ [link fusion.algorithms.query.functions.count_if `count_if`]]
-[def __result_of_count_if__ [link fusion.algorithms.query.metafunctions.count_if `result_of::count_if`]]
-[def __filter__ [link fusion.algorithms.transformation.functions.filter `filter`]]
-[def __result_of_filter__ [link fusion.algorithms.transformation.metafunctions.filter `result_of::filter`]]
-[def __filter_if__ [link fusion.algorithms.transformation.functions.filter_if `filter_if`]]
-[def __result_of_filter_if__ [link fusion.algorithms.transformation.metafunctions.filter_if `result_of::filter_if`]]
-[def __transform__ [link fusion.algorithms.transformation.functions.transform `transform`]]
-[def __result_of_transform__ [link fusion.algorithms.transformation.metafunctions.transform `result_of::transform`]]
-[def __replace__ [link fusion.algorithms.transformation.functions.replace `replace`]]
-[def __result_of_replace__ [link fusion.algorithms.transformation.metafunctions.replace `result_of::replace`]]
-[def __replace_if__ [link fusion.algorithms.transformation.functions.replace_if `replace_if`]]
-[def __result_of_replace_if__ [link fusion.algorithms.transformation.metafunctions.replace_if `result_of::replace_if`]]
-[def __remove__ [link fusion.algorithms.transformation.functions.remove `remove`]]
-[def __result_of_remove__ [link fusion.algorithms.transformation.metafunctions.remove `result_of::remove`]]
-[def __remove_if__ [link fusion.algorithms.transformation.functions.remove_if `remove_if`]]
-[def __result_of_remove_if__ [link fusion.algorithms.transformation.metafunctions.remove_if `result_of::remove_if`]]
-[def __reverse__ [link fusion.algorithms.transformation.functions.reverse `reverse`]]
-[def __result_of_reverse__ [link fusion.algorithms.transformation.metafunctions.reverse `result_of::reverse`]]
-[def __clear__ [link fusion.algorithms.transformation.functions.clear `clear`]]
-[def __result_of_clear__ [link fusion.algorithms.transformation.metafunctions.clear `result_of::clear`]]
-[def __erase__ [link fusion.algorithms.transformation.functions.erase `erase`]]
-[def __result_of_erase__ [link fusion.algorithms.transformation.metafunctions.erase `result_of::erase`]]
-[def __erase_key__ [link fusion.algorithms.transformation.functions.erase_key `erase_key`]]
-[def __result_of_erase_key__ [link fusion.algorithms.transformation.metafunctions.erase_key `result_of::erase_key`]]
-[def __insert__ [link fusion.algorithms.transformation.functions.insert `insert`]]
-[def __result_of_insert__ [link fusion.algorithms.transformation.metafunctions.insert `result_of::insert`]]
-[def __insert_range__ [link fusion.algorithms.transformation.functions.insert_range `insert_range`]]
-[def __result_of_insert_range__ [link fusion.algorithms.transformation.metafunctions.insert_range `result_of::insert_range`]]
-[def __join__ [link fusion.algorithms.transformation.functions.join `join`]]
-[def __result_of_join__ [link fusion.algorithms.transformation.metafunctions.join `result_of::join`]]
-[def __zip__ [link fusion.algorithms.transformation.functions.zip `zip`]]
-[def __result_of_zip__ [link fusion.algorithms.transformation.metafunctions.zip `result_of::zip`]]
-[def __pop_back__ [link fusion.algorithms.transformation.functions.pop_back `pop_back`]]
-[def __result_of_pop_back__ [link fusion.algorithms.transformation.metafunctions.pop_back `result_of::pop_back`]]
-[def __pop_front__ [link fusion.algorithms.transformation.functions.pop_front `pop_front`]]
-[def __result_of_pop_front__ [link fusion.algorithms.transformation.metafunctions.pop_front `result_of::pop_front`]]
-[def __push_back__ [link fusion.algorithms.transformation.functions.push_back `push_back`]]
-[def __result_of_push_back__ [link fusion.algorithms.transformation.metafunctions.push_back `result_of::push_back`]]
-[def __push_front__ [link fusion.algorithms.transformation.functions.push_front `push_front`]]
-[def __result_of_push_front__ [link fusion.algorithms.transformation.metafunctions.push_front `result_of::push_front`]]
+[def __algorithm__ [link fusion.algorithm Algorithm]]
+[def __algorithms__ [link fusion.algorithm Algorithms]]
+[def __fold__ [link fusion.algorithm.iteration.functions.fold `fold`]]
+[def __result_of_fold__ [link fusion.algorithm.iteration.metafunctions.fold `result_of::fold`]]
+[def __accumulate__ [link fusion.algorithm.iteration.functions.accumulate `accumulate`]]
+[def __result_of_accumulate__ [link fusion.algorithm.iteration.metafunctions.accumulate `result_of::accumulate`]]
+[def __for_each__ [link fusion.algorithm.iteration.functions.for_each `for_each`]]
+[def __result_of_for_each__ [link fusion.algorithm.iteration.metafunctions.for_each `result_of::for_each`]]
+[def __any__ [link fusion.algorithm.query.functions.any `any`]]
+[def __result_of_any__ [link fusion.algorithm.query.metafunctions.any `result_of::any`]]
+[def __all__ [link fusion.algorithm.query.functions.all `all`]]
+[def __result_of_all__ [link fusion.algorithm.query.metafunctions.all `result_of::all`]]
+[def __none__ [link fusion.algorithm.query.functions.none `none`]]
+[def __result_of_none__ [link fusion.algorithm.query.metafunctions.none `result_of::none`]]
+[def __find__ [link fusion.algorithm.query.functions.find `find`]]
+[def __result_of_find__ [link fusion.algorithm.query.metafunctions.find `result_of::find`]]
+[def __find_if__ [link fusion.algorithm.query.functions.find_if `find_if`]]
+[def __result_of_find_if__ [link fusion.algorithm.query.metafunctions.find_if `result_of::find_if`]]
+[def __count__ [link fusion.algorithm.query.functions.count `count`]]
+[def __result_of_count__ [link fusion.algorithm.query.metafunctions.count `result_of::count`]]
+[def __count_if__ [link fusion.algorithm.query.functions.count_if `count_if`]]
+[def __result_of_count_if__ [link fusion.algorithm.query.metafunctions.count_if `result_of::count_if`]]
+[def __filter__ [link fusion.algorithm.transformation.functions.filter `filter`]]
+[def __result_of_filter__ [link fusion.algorithm.transformation.metafunctions.filter `result_of::filter`]]
+[def __filter_if__ [link fusion.algorithm.transformation.functions.filter_if `filter_if`]]
+[def __result_of_filter_if__ [link fusion.algorithm.transformation.metafunctions.filter_if `result_of::filter_if`]]
+[def __transform__ [link fusion.algorithm.transformation.functions.transform `transform`]]
+[def __result_of_transform__ [link fusion.algorithm.transformation.metafunctions.transform `result_of::transform`]]
+[def __replace__ [link fusion.algorithm.transformation.functions.replace `replace`]]
+[def __result_of_replace__ [link fusion.algorithm.transformation.metafunctions.replace `result_of::replace`]]
+[def __replace_if__ [link fusion.algorithm.transformation.functions.replace_if `replace_if`]]
+[def __result_of_replace_if__ [link fusion.algorithm.transformation.metafunctions.replace_if `result_of::replace_if`]]
+[def __remove__ [link fusion.algorithm.transformation.functions.remove `remove`]]
+[def __result_of_remove__ [link fusion.algorithm.transformation.metafunctions.remove `result_of::remove`]]
+[def __remove_if__ [link fusion.algorithm.transformation.functions.remove_if `remove_if`]]
+[def __result_of_remove_if__ [link fusion.algorithm.transformation.metafunctions.remove_if `result_of::remove_if`]]
+[def __reverse__ [link fusion.algorithm.transformation.functions.reverse `reverse`]]
+[def __result_of_reverse__ [link fusion.algorithm.transformation.metafunctions.reverse `result_of::reverse`]]
+[def __clear__ [link fusion.algorithm.transformation.functions.clear `clear`]]
+[def __result_of_clear__ [link fusion.algorithm.transformation.metafunctions.clear `result_of::clear`]]
+[def __erase__ [link fusion.algorithm.transformation.functions.erase `erase`]]
+[def __result_of_erase__ [link fusion.algorithm.transformation.metafunctions.erase `result_of::erase`]]
+[def __erase_key__ [link fusion.algorithm.transformation.functions.erase_key `erase_key`]]
+[def __result_of_erase_key__ [link fusion.algorithm.transformation.metafunctions.erase_key `result_of::erase_key`]]
+[def __insert__ [link fusion.algorithm.transformation.functions.insert `insert`]]
+[def __result_of_insert__ [link fusion.algorithm.transformation.metafunctions.insert `result_of::insert`]]
+[def __insert_range__ [link fusion.algorithm.transformation.functions.insert_range `insert_range`]]
+[def __result_of_insert_range__ [link fusion.algorithm.transformation.metafunctions.insert_range `result_of::insert_range`]]
+[def __join__ [link fusion.algorithm.transformation.functions.join `join`]]
+[def __result_of_join__ [link fusion.algorithm.transformation.metafunctions.join `result_of::join`]]
+[def __zip__ [link fusion.algorithm.transformation.functions.zip `zip`]]
+[def __result_of_zip__ [link fusion.algorithm.transformation.metafunctions.zip `result_of::zip`]]
+[def __pop_back__ [link fusion.algorithm.transformation.functions.pop_back `pop_back`]]
+[def __result_of_pop_back__ [link fusion.algorithm.transformation.metafunctions.pop_back `result_of::pop_back`]]
+[def __pop_front__ [link fusion.algorithm.transformation.functions.pop_front `pop_front`]]
+[def __result_of_pop_front__ [link fusion.algorithm.transformation.metafunctions.pop_front `result_of::pop_front`]]
+[def __push_back__ [link fusion.algorithm.transformation.functions.push_back `push_back`]]
+[def __result_of_push_back__ [link fusion.algorithm.transformation.metafunctions.push_back `result_of::push_back`]]
+[def __push_front__ [link fusion.algorithm.transformation.functions.push_front `push_front`]]
+[def __result_of_push_front__ [link fusion.algorithm.transformation.metafunctions.push_front `result_of::push_front`]]
 
 [def __tr1_tuple_pair__ [link fusion.tuple.pairs `TR1 and std::pair`]]
 [def __tuple_get__ [link fusion.tuple.class_template_tuple.element_access `get`]]
@@ -303,7 +303,7 @@
 [include container.qbk]
 [include view.qbk]
 [include adapted.qbk]
-[include algorithms.qbk]
+[include algorithm.qbk]
 [include tuple.qbk]
 [include extension.qbk]
 [include functional.qbk]

Modified: trunk/libs/fusion/doc/organization.qbk
==============================================================================
--- trunk/libs/fusion/doc/organization.qbk (original)
+++ trunk/libs/fusion/doc/organization.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -52,14 +52,13 @@
     * map
     * set
     * vector
+ * generation
 * mpl
 * functional
 * sequence
     * comparison
- * conversion
     * intrinsic
     * io
- * utility
 * iterator
 * support
 
@@ -69,7 +68,9 @@
 you desire, you may do so by including one of
 
     #include <boost/fusion/container.hpp>
+ #include <boost/fusion/include/container.hpp>
     #include <boost/fusion/container/list.hpp>
+ #include <boost/fusion/include/list.hpp>
 
 The first includes all containers The second includes only `list`
 [footnote Modules may contain smaller components. Header file

Modified: trunk/libs/fusion/doc/quick_start.qbk
==============================================================================
--- trunk/libs/fusion/doc/quick_start.qbk (original)
+++ trunk/libs/fusion/doc/quick_start.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -11,6 +11,7 @@
 details).]:
 
     #include <boost/fusion/sequence.hpp>
+ #include <boost/fusion/include/sequence.hpp>
 
 Let's begin with a `__vector__` [footnote Unless otherwise noted, components are
 in namespace `boost::fusion`. For the sake of simplicity, code in this
@@ -32,6 +33,7 @@
 First, let's include the algorithms:
 
     #include <boost/fusion/algorithm.hpp>
+ #include <boost/fusion/include/algorithm.hpp>
     
 Now, let's write a function object that prints XML of the form <type>data</type>
 for each member in the tuple.

Modified: trunk/libs/fusion/doc/sequence.qbk
==============================================================================
--- trunk/libs/fusion/doc/sequence.qbk (original)
+++ trunk/libs/fusion/doc/sequence.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -11,6 +11,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence.hpp>
+ #include <boost/fusion/include/sequence.hpp>
 
 [section Concepts]
 
@@ -349,6 +350,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic.hpp>
+ #include <boost/fusion/include/intrinsic.hpp>
 
 [section Functions]
 
@@ -388,6 +390,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/begin.hpp>
+ #include <boost/fusion/include/begin.hpp>
 
 [heading Example]
 
@@ -433,6 +436,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/end.hpp>
+ #include <boost/fusion/include/end.hpp>
 
 [heading Example]
 
@@ -473,6 +477,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/empty.hpp>
+ #include <boost/fusion/include/empty.hpp>
 
 [heading Example]
 
@@ -520,6 +525,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/front.hpp>
+ #include <boost/fusion/include/front.hpp>
 
 [heading Example]
 
@@ -567,6 +573,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/back.hpp>
+ #include <boost/fusion/include/back.hpp>
 
 [heading Example]
 
@@ -606,6 +613,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/size.hpp>
+ #include <boost/fusion/include/size.hpp>
 
 [heading Example]
 
@@ -658,6 +666,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/at.hpp>
+ #include <boost/fusion/include/at.hpp>
 
 [heading Example]
 
@@ -710,6 +719,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/at_c.hpp>
+ #include <boost/fusion/include/at_c.hpp>
 
 [heading Example]
 
@@ -752,6 +762,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/has_key.hpp>
+ #include <boost/fusion/include/has_key.hpp>
 
 [heading Example]
 
@@ -800,6 +811,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/intrinsic/at_key.hpp>
+ #include <boost/fusion/include/at_key.hpp>
 
 [heading Example]
 
@@ -1340,1175 +1352,6 @@
 
 [endsect]
 
-[section Generation]
-
-These are the functions that you can use to generate various forms of
-__containers__ from elemental values.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation.hpp>
-
-[section Functions]
-
-[section make_list]
-
-[heading Description]
-
-Create a __list__ from one or more values.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- typename __result_of_make_list__<T0, T1,... TN>::type
- make_list(T0 const& x0, T1 const& x1... TN const& xN);
-
-The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
-`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
-to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
-before including any Fusion header to change the default. Example:
-
- #define FUSION_MAX_LIST_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_list`]]
-]
-
-[heading Expression Semantics]
-
- make_list(x0, x1,... xN);
-
-[*Return type]: __result_of_make_list__`<T0, T1,... TN>::type`
-
-[*Semantics]: Create a __list__ from `x0, x1,... xN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_list.hpp>
-
-[heading Example]
-
- make_list(123, "hello", 12.5)
-
-[heading See also]
-
-__note_boost_ref__
-
-[endsect]
-
-[section make_cons]
-
-[heading Description]
-
-Create a __cons__ from `car` (/head/) and optional `cdr` (/tail/).
-
-[heading Synopsis]
-
- template <typename Car>
- typename __result_of_make_cons__<Car>::type
- make_cons(Car const& car);
-
- template <typename Car, typename Cdr>
- typename __result_of_make_cons__<Car, Cdr>::type
- make_cons(Car const& car, Cdr const& cdr);
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`car`] [Instance of `Car`] [The list's head]]
- [[`cdr`] [Instance of `Cdr`] [The list's tail (optional)]]
-]
-
-[heading Expression Semantics]
-
- make_cons(car, cdr);
-
-[*Return type]: __result_of_make_cons__`<Car, Cdr>::type` or
-__result_of_make_cons__`<Car>::type`
-
-[*Semantics]: Create a __cons__ from `car` (/head/) and optional `cdr` (/tail/).
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_cons.hpp>
-
-[heading Example]
-
- make_cons('x', make_cons(123))
-
-[heading See also]
-
-__note_boost_ref__
-
-[endsect]
-
-[section make_vector]
-
-[heading Description]
-
-Create a __vector__ from one or more values.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- typename __result_of_make_vector__<T0, T1,... TN>::type
- make_vector(T0 const& x0, T1 const& x1... TN const& xN);
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
-where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
-defaults to `10`. You may define the preprocessor constant
-`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
-default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_vector`]]
-]
-
-[heading Expression Semantics]
-
- make_vector(x0, x1,... xN);
-
-[*Return type]: __result_of_make_vector__`<T0, T1,... TN>::type`
-
-[*Semantics]: Create a __vector__ from `x0, x1,... xN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_vector.hpp>
-
-[heading Example]
-
- make_vector(123, "hello", 12.5)
-
-[heading See also]
-
-__note_boost_ref__
-
-[endsect]
-
-[section make_set]
-
-[heading Description]
-
-Create a __set__ from one or more values.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- typename __result_of_make_set__<T0, T1,... TN>::type
- make_set(T0 const& x0, T1 const& x1... TN const& xN);
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
-`set` is implemented in terms of the vector. That is why we reuse
-`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
-definable predefined maximum that defaults to `10`. You may define the
-preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
-header to change the default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_set`]]
-]
-
-[heading Expression Semantics]
-
- make_set(x0, x1,... xN);
-
-[*Return type]: __result_of_make_set__`<T0, T1,... TN>::type`
-
-[*Semantics]: Create a __set__ from `x0, x1,... xN`.
-
-[*Precondition]: There may be no duplicate key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_set.hpp>
-
-[heading Example]
-
- make_set(123, "hello", 12.5)
-
-[heading See also]
-
-__note_boost_ref__
-
-[endsect]
-
-[section make_map]
-
-[heading Description]
-
-Create a __map__ from one or more key/data pairs.
-
-[heading Synopsis]
-
- template <
- typename K0, typename K1,... typename KN
- , typename T0, typename T1,... typename TN>
- typename __result_of_make_map__<K0, K0,... KN, T0, T1,... TN>::type
- make_map(T0 const& x0, T1 const& x1... TN const& xN);
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
-`map` is implemented in terms of the vector. That is why we reuse
-`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
-definable predefined maximum that defaults to `10`. You may define the
-preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
-header to change the default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`K0, K1,... KN`] [The key types] [Keys associated with `x0, x1,... xN`]]
- [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `make_map`]]
-]
-
-[heading Expression Semantics]
-
- make_map<K0, K1,... KN>(x0, x1,... xN);
-
-[*Return type]: __result_of_make_map__`<K0, K0,... KN, T0, T1,... TN>::type`
-
-[*Semantics]: Create a __map__ from `K0, K1,... KN` keys and
-`x0, x1,... xN` data.
-
-[*Precondition]: There may be no duplicate key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_map.hpp>
-
-[heading Example]
-
- make_map(
- __fusion_make_pair__<int>('X')
- , __fusion_make_pair__<double>("Men"))
-
-[heading See also]
-
-__note_boost_ref__, __fusion_pair__
-
-[endsect]
-
-[section Tiers]
-
-Tiers are sequences, where all elements are non-const reference types. They
-are constructed with a call to a couple of /tie/ function templates. The
-succeeding sections document the various /tier/ flavors.
-
-* __list_tie__
-* __vector_tie__
-* __map_tie__
-
-Example:
-
- int i; char c; double d;
- ...
- __vector_tie__(i, c, a);
-
-The __vector_tie__ function creates a __vector__ of type
-`__vector__<int&, char&, double&>`. The same result could be achieved with the call
-__make_vector__(__boost_ref_call__(i), __boost_ref_call__(c), __boost_ref_call__(a))
-[footnote see __boost_ref__ for details about `ref`].
-
-A /tie/ can be used to 'unpack' another tuple into variables. E.g.:
-
- int i; char c; double d;
- __vector_tie__(i, c, d) = __make_vector__(1,'a', 5.5);
- std::cout << i << " " << c << " " << d;
-
-This code prints 1 a 5.5 to the standard output stream. A sequence
-unpacking operation like this is found for example in ML and Python. It is
-convenient when calling functions which return sequences.
-
-[heading Ignore]
-
-There is also an object called /ignore/ which allows you to ignore an
-element assigned by a sequence. The idea is that a function may return a
-sequence, only part of which you are interested in. For example:
-
- char c;
- __vector_tie__(ignore, c) = __make_vector__(1, 'a');
-
-[endsect]
-
-[section list_tie]
-
-[heading Description]
-
-Constructs a tie using a __list__ sequence.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- __list__<T0&, T1&,... TN&>
- list_tie(T0& x0, T1& x1... TN& xN);
-
-The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
-`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
-to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
-before including any Fusion header to change the default. Example:
-
- #define FUSION_MAX_LIST_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `list_tie`]]
-]
-
-[heading Expression Semantics]
-
- list_tie(x0, x1,... xN);
-
-[*Return type]: __list__<T0&, T1&,... TN&>
-
-[*Semantics]: Create a __list__ of references from `x0, x1,... xN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/list_tie.hpp>
-
-[heading Example]
-
- int i = 123;
- double d = 123.456;
- list_tie(i, d)
-
-[endsect]
-
-[section vector_tie]
-
-[heading Description]
-
-Constructs a tie using a __vector__ sequence.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- __vector__<T0&, T1&,... TN&>
- vector_tie(T0& x0, T1& x1... TN& xN);
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
-where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
-defaults to `10`. You may define the preprocessor constant
-`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
-default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `vector_tie`]]
-]
-
-[heading Expression Semantics]
-
- vector_tie(x0, x1,... xN);
-
-[*Return type]: __vector__<T0&, T1&,... TN&>
-
-[*Semantics]: Create a __vector__ of references from `x0, x1,... xN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/vector_tie.hpp>
-
-[heading Example]
-
- int i = 123;
- double d = 123.456;
- vector_tie(i, d)
-
-[endsect]
-
-[section map_tie]
-
-[heading Description]
-
-Constructs a tie using a __map__ sequence.
-
-[heading Synopsis]
-
- template <typename K0, typename K1,... typename KN, typename D0, typename D1,... typename DN>
- __map__<__pair__<K0, D0&>, __pair__<K1, D1&>,... __pair__<KN, DN&> >
- map_tie(D0& d0, D1& d1... DN& dN);
-
-The variadic function accepts `0` to `FUSION_MAX_MAP_SIZE` elements,
-where `FUSION_MAX_MAP_SIZE` is a user definable predefined maximum that
-defaults to `10`, and a corresponding number of key types.
-You may define the preprocessor constant `FUSION_MAX_MAP_SIZE` before
-including any Fusion header to change the default. Example:
-
- #define FUSION_MAX_MAP_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`K0, K1,... KN`] [Any type][The key types associated with each of the `x1,x2,...,xN` values]]
- [[`x0, x1,... xN`] [Instances of `T0, T1,... TN`] [The arguments to `map_tie`]]
-]
-
-[heading Expression Semantics]
-
- map_tie<K0, K1,... KN>(x0, x1,... xN);
-
-[*Return type]: __map__<__pair__<K0, D0&>, __pair__<K1, D1&>,... __pair__<KN, DN&> >
-
-[*Semantics]: Create a __map__ of references from `x0, x1,... xN` with keys `K0, K1,... KN`
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/map_tie.hpp>
-
-[heading Example]
-
- struct int_key;
- struct double_key;
- ...
- int i = 123;
- double d = 123.456;
- map_tie<int_key, double_key>(i, d)
-
-[endsect]
-
-[endsect]
-
-[section MetaFunctions]
-
-[section make_list]
-
-[heading Description]
-
-Returns the result type of __make_list__.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- struct make_list;
-
-The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
-`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
-to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
-before including any Fusion header to change the default. Example:
-
- #define FUSION_MAX_LIST_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`T0, T1,... TN`] [Any type] [Template arguments to `make_list`]]
-]
-
-[heading Expression Semantics]
-
- result_of::make_list<T0, T1,... TN>::type
-
-[*Return type]: A __list__ with elements of types converted following the
-rules for __element_conversion__.
-
-[*Semantics]: Create a __list__ from `T0, T1,... TN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_list.hpp>
-
-[heading Example]
-
- result_of::make_list<int, const char(&)[7], double>::type
-
-[endsect]
-
-[section make_cons]
-
-[heading Description]
-
-Returns the result type of __make_cons__.
-
-[heading Synopsis]
-
- template <typename Car, typename Cdr = nil>
- struct make_cons;
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`Car`] [Any type] [The list's head type]]
- [[`Cdr`] [A `cons`] [The list's tail type (optional)]]
-]
-
-[heading Expression Semantics]
-
- result_of::make_cons<Car, Cdr>::type
-
-[*Return type]: A __cons__ with head element, `Car`, of type converted
-following the rules for __element_conversion__, and tail, `Cdr`.
-
-[*Semantics]: Create a __cons__ from `Car` (/head/) and optional `Cdr` (/tail/).
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_cons.hpp>
-
-[heading Example]
-
- result_of::make_cons<char, result_of::make_cons<int>::type>::type
-
-[endsect]
-
-[section make_vector]
-
-[heading Description]
-
-Returns the result type of __make_vector__.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- struct make_vector;
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
-where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
-defaults to `10`. You may define the preprocessor constant
-`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
-default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`T0, T1,... TN`] [Any type] [Template arguments to `make_vector`]]
-]
-
-[heading Expression Semantics]
-
- result_of::make_vector<T0, T1,... TN>::type
-
-[*Return type]: A __vector__ with elements of types converted following the
-rules for __element_conversion__.
-
-[*Semantics]: Create a __vector__ from `T0, T1,... TN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_list.hpp>
-
-[heading Example]
-
- result_of::make_vector<int, const char(&)[7], double>::type
-
-[endsect]
-
-[section make_set]
-
-[heading Description]
-
-Returns the result type of __make_set__.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- struct make_set;
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
-`set` is implemented in terms of the vector. That is why we reuse
-`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
-definable predefined maximum that defaults to `10`. You may define the
-preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
-header to change the default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`T0, T1,... TN`] [Any type] [The arguments to `make_set`]]
-]
-
-[heading Expression Semantics]
-
- result_of::make_set<T0, T1,... TN>::type
-
-[*Return type]: A __set__ with elements of types converted following the
-rules for __element_conversion__.
-
-[*Semantics]: Create a __set__ from `T0, T1,... TN`.
-
-[*Precondition]: There may be no duplicate key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_set.hpp>
-
-[heading Example]
-
- result_of::make_set<int, char, double>::type
-
-[endsect]
-
-[section make_map]
-
-[heading Description]
-
-Returns the result type of __make_map__.
-
-[heading Synopsis]
-
- template <
- typename K0, typename K1,... typename KN
- , typename T0, typename T1,... typename TN>
- struct make_map;
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE`[footnote
-`map` is implemented in terms of the vector. That is why we reuse
-`FUSION_MAX_VECTOR_SIZE`] elements, where `FUSION_MAX_VECTOR_SIZE` is a user
-definable predefined maximum that defaults to `10`. You may define the
-preprocessor constant `FUSION_MAX_VECTOR_SIZE` before including any Fusion
-header to change the default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`K0, K1,... KN`] [Any type] [Keys associated with `T0, T1,... TN`]]
- [[`T0, T1,... TN`] [Any type] [Data associated with keys `K0, K1,... KN`]]
-]
-
-[heading Expression Semantics]
-
- resulf_of::make_map<K0, K1,... KN, T0, T1,... TN>::type;
-
-[*Return type]: __result_of_make_map__`<K0, K0,... KN, T0, T1,... TN>::type`
-
-[*Semantics]: A __map__ with __fusion_pair__ elements where the
-`second_type` is converted following the rules for __element_conversion__.
-
-[*Precondition]: There may be no duplicate key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/make_map.hpp>
-
-[heading Example]
-
- result_of::make_map<int, double, char, double>::type
-
-[heading See also]
-
-__fusion_pair__
-
-[endsect]
-
-[section list_tie]
-
-[heading Description]
-
-Returns the result type of __list_tie__.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- struct list_tie;
-
-The variadic function accepts `0` to `FUSION_MAX_LIST_SIZE` elements, where
-`FUSION_MAX_LIST_SIZE` is a user definable predefined maximum that defaults
-to `10`. You may define the preprocessor constant `FUSION_MAX_LIST_SIZE`
-before including any Fusion header to change the default. Example:
-
- #define FUSION_MAX_LIST_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`T0, T1,... TN`] [Any type] [The arguments to `list_tie`]]
-]
-
-[heading Expression Semantics]
-
- result_of::list_tie<T0, T1,... TN>::type;
-
-[*Return type]: __list__<T0&, T1&,... TN&>
-
-[*Semantics]: Create a __list__ of references from `T0, T1,... TN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/list_tie.hpp>
-
-[heading Example]
-
- result_of::list_tie<int, double>::type
-
-[endsect]
-
-[section vector_tie]
-
-[heading Description]
-
-Returns the result type of __vector_tie__.
-
-[heading Synopsis]
-
- template <typename T0, typename T1,... typename TN>
- struct vector_tie;
-
-The variadic function accepts `0` to `FUSION_MAX_VECTOR_SIZE` elements,
-where `FUSION_MAX_VECTOR_SIZE` is a user definable predefined maximum that
-defaults to `10`. You may define the preprocessor constant
-`FUSION_MAX_VECTOR_SIZE` before including any Fusion header to change the
-default. Example:
-
- #define FUSION_MAX_VECTOR_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`T0, T1,... TN`] [Any type] [The arguments to `vector_tie`]]
-]
-
-[heading Expression Semantics]
-
- result_of::vector_tie<T0, T1,... TN>::type;
-
-[*Return type]: __vector__<T0&, T1&,... TN&>
-
-[*Semantics]: Create a __vector__ of references from `T0, T1,... TN`.
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/vector_tie.hpp>
-
-[heading Example]
-
- result_of::vector_tie<int, double>::type
-
-[endsect]
-
-[section map_tie]
-
-[heading Description]
-
-Returns the result type of __map_tie__.
-
-[heading Synopsis]
-
- template <typename K0, typename K1,... typename KN, typename D0, typename D1,... typename DN>
- struct map_tie;
-
-The variadic function accepts `0` to `FUSION_MAX_MAP_SIZE` elements,
-where `FUSION_MAX_MAP_SIZE` is a user definable predefined maximum that
-defaults to `10`. You may define the preprocessor constant
-`FUSION_MAX_MAP_SIZE` before including any Fusion header to change the
-default. Example:
-
- #define FUSION_MAX_MAP_SIZE 20
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`K0, K1,... KN`] [Any type] [The key types for `map_tie`]]
- [[`D0, D1,... DN`] [Any type] [The arguments types for `map_tie`]]
-]
-
-[heading Expression Semantics]
-
- result_of::map_tie<K0, K1,... KN, D0, D1,... DN>::type;
-
-[*Return type]: __map__<__pair__<K0, D0&>, __pair__<K1, D1&>,... __pair__<KN, DN&> >
-
-[*Semantics]: Create a __map__ of references from `D0, D1,... DN` with keys `K0, K1,... KN`
-
-[heading Header]
-
- #include <boost/fusion/sequence/generation/map_tie.hpp>
-
-[heading Example]
-
- struct int_key;
- struct double_key;
- ...
- result_of::map_tie<int_key, double_key, int, double>::type
-
-[endsect]
-
-[endsect]
-
-[endsect]
-
-[section Conversion]
-
-All fusion sequences can be converted to one of the __containers__ types
-using one of these conversion functions.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion.hpp>
-
-[section Functions]
-
-[section as_list]
-
-[heading Description]
-
-Convert a fusion sequence to a __list__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- typename result_of::as_list<Sequence>::type
- as_list(Sequence& seq);
-
- template <typename Sequence>
- typename result_of::as_list<Sequence const>::type
- as_list(Sequence const& seq);
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`seq`] [An instance of Sequence] [The sequence to convert.]]
-]
-
-[heading Expression Semantics]
-
- as_list(seq);
-
-[*Return type]: __result_of_as_list__`<Sequence>::type`
-
-[*Semantics]: Convert a fusion sequence, `seq`, to a __list__.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_list.hpp>
-
-[heading Example]
-
- as_list(__make_vector__('x', 123, "hello"))
-
-[endsect]
-
-[section as_vector]
-
-[heading Description]
-
-Convert a fusion sequence to a __vector__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- typename result_of::as_vector<Sequence>::type
- as_vector(Sequence& seq);
-
- template <typename Sequence>
- typename result_of::as_vector<Sequence const>::type
- as_vector(Sequence const& seq);
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`seq`] [An instance of Sequence] [The sequence to convert.]]
-]
-
-[heading Expression Semantics]
-
- as_vector(seq);
-
-[*Return type]: __result_of_as_vector__`<Sequence>::type`
-
-[*Semantics]: Convert a fusion sequence, `seq`, to a __vector__.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_vector.hpp>
-
-[heading Example]
-
- as_vector(__make_list__('x', 123, "hello"))
-
-[endsect]
-
-[section as_set]
-
-[heading Description]
-
-Convert a fusion sequence to a __set__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- typename result_of::as_set<Sequence>::type
- as_set(Sequence& seq);
-
- template <typename Sequence>
- typename result_of::as_set<Sequence const>::type
- as_set(Sequence const& seq);
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`seq`] [An instance of Sequence] [The sequence to convert.]]
-]
-
-[heading Expression Semantics]
-
- as_set(seq);
-
-[*Return type]: __result_of_as_set__`<Sequence>::type`
-
-[*Semantics]: Convert a fusion sequence, `seq`, to a __set__.
-
-[*Precondition]: There may be no duplicate key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_set.hpp>
-
-[heading Example]
-
- as_set(__make_vector__('x', 123, "hello"))
-
-[endsect]
-
-[section as_map]
-
-[heading Description]
-
-Convert a fusion sequence to a __map__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- typename result_of::as_map<Sequence>::type
- as_map(Sequence& seq);
-
- template <typename Sequence>
- typename result_of::as_map<Sequence const>::type
- as_map(Sequence const& seq);
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`seq`] [An instance of Sequence] [The sequence to convert.]]
-]
-
-[heading Expression Semantics]
-
- as_map(seq);
-
-[*Return type]: __result_of_as_map__`<Sequence>::type`
-
-[*Semantics]: Convert a fusion sequence, `seq`, to a __map__.
-
-[*Precondition]: The elements of the sequence are assumed to be
-__fusion_pair__s. There may be no duplicate __fusion_pair__ key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_map.hpp>
-
-[heading Example]
-
- as_map(__make_vector__(
- __fusion_make_pair__<int>('X')
- , __fusion_make_pair__<double>("Men")))
-
-[endsect]
-
-[endsect]
-
-[section Metafunctions]
-
-[section as_list]
-
-[heading Description]
-
-Returns the result type of __as_list__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- struct as_list;
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A fusion __sequence__] [The sequence type to convert.]]
-]
-
-[heading Expression Semantics]
-
- result_of::as_list<Sequence>::type;
-
-[*Return type]: A __list__ with same elements as the input sequence,
-`Sequence`.
-
-[*Semantics]: Convert a fusion sequence, `Sequence`, to a __list__.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_list.hpp>
-
-[heading Example]
-
- result_of::as_list<__vector__<char, int> >::type
-
-[endsect]
-
-[section as_vector]
-
-[heading Description]
-
-Returns the result type of __as_vector__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- struct as_vector;
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A fusion __sequence__] [The sequence to convert.]]
-]
-
-[heading Expression Semantics]
-
- result_of::as_vector<Sequence>::type;
-
-[*Return type]: A __vector__ with same elements as the input sequence,
-`Sequence`.
-
-[*Semantics]: Convert a fusion sequence, `Sequence`, to a __vector__.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_vector.hpp>
-
-[heading Example]
-
- result_of::as_vector<__list__<char, int> >::type
-
-[endsect]
-
-[section as_set]
-
-[heading Description]
-
-Returns the result type of __as_set__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- struct as_set;
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A fusion __sequence__] [The sequence to convert.]]
-]
-
-[heading Expression Semantics]
-
- result_of::as_set<Sequence>::type;
-
-[*Return type]: A __set__ with same elements as the input sequence,
-`Sequence`.
-
-[*Semantics]: Convert a fusion sequence, `Sequence`, to a __set__.
-
-[*Precondition]: There may be no duplicate key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_set.hpp>
-
-[heading Example]
-
- result_of::as_set<__vector__<char, int> >::type
-
-[endsect]
-
-[section as_map]
-
-[heading Description]
-
-Returns the result type of __as_map__.
-
-[heading Synopsis]
-
- template <typename Sequence>
- struct as_map;
-
-[heading Parameters]
-
-[table
- [[Parameter] [Requirement] [Description]]
- [[`Sequence`] [A fusion __sequence__] [The sequence to convert.]]
-]
-
-[heading Expression Semantics]
-
- result_of::as_map<Sequence>::type;
-
-[*Return type]: A __map__ with same elements as the input sequence,
-`Sequence`.
-
-[*Semantics]: Convert a fusion sequence, `Sequence`, to a __map__.
-
-[*Precondition]: The elements of the sequence are assumed to be
-__fusion_pair__s. There may be no duplicate __fusion_pair__ key types.
-
-[heading Header]
-
- #include <boost/fusion/sequence/conversion/as_map.hpp>
-
-[heading Example]
-
- result_of::as_map<__vector__<
- __fusion_pair__<int, char>
- , __fusion_pair__<double, std::string> > >::type
-
-[endsect]
-
-[endsect]
-
-[endsect]
-
 [section Operator]
 
 These operators, like the __algorithms__, work generically on all Fusion
@@ -2572,6 +1415,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/io.hpp>
+ #include <boost/fusion/include/io.hpp>
 
 [section in]
 
@@ -2604,6 +1448,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/io/in.hpp>
+ #include <boost/fusion/include/in.hpp>
 
 [heading Example]
 
@@ -2643,6 +1488,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/io/out.hpp>
+ #include <boost/fusion/include/out.hpp>
 
 [heading Example]
 
@@ -2662,6 +1508,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/comparison.hpp>
+ #include <boost/fusion/include/comparison.hpp>
 
 [section equal]
 
@@ -2706,6 +1553,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/comparison/equal_to.hpp>
+ #include <boost/fusion/include/equal_to.hpp>
 
 [heading Example]
 
@@ -2754,6 +1602,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/comparison/not_equal_to.hpp>
+ #include <boost/fusion/include/not_equal_to.hpp>
 
 [heading Example]
 
@@ -2802,6 +1651,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/comparison/less.hpp>
+ #include <boost/fusion/include/less.hpp>
 
 [heading Example]
 
@@ -2850,6 +1700,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/comparison/less_equal.hpp>
+ #include <boost/fusion/include/less_equal.hpp>
 
 [heading Example]
 
@@ -2898,6 +1749,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/comparison/less_equal.hpp>
+ #include <boost/fusion/include/less_equal.hpp>
 
 [heading Example]
 
@@ -2946,6 +1798,7 @@
 [heading Header]
 
     #include <boost/fusion/sequence/comparison/greater_equal.hpp>
+ #include <boost/fusion/include/greater_equal.hpp>
 
 [heading Example]
 

Modified: trunk/libs/fusion/doc/support.qbk
==============================================================================
--- trunk/libs/fusion/doc/support.qbk (original)
+++ trunk/libs/fusion/doc/support.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -40,6 +40,7 @@
 [heading Header]
 
     #include <boost/fusion/support/is_sequence.hpp>
+ #include <boost/fusion/include/is_sequence.hpp>
 
 [heading Example]
 
@@ -93,6 +94,7 @@
 [heading Header]
 
     #include <boost/fusion/support/is_view.hpp>
+ #include <boost/fusion/include/is_view.hpp>
 
 [heading Example]
 
@@ -147,6 +149,7 @@
 [heading Header]
 
     #include <boost/fusion/support/tag_of.hpp>
+ #include <boost/fusion/include/tag_of.hpp>
 
 [heading Example]
 
@@ -243,6 +246,7 @@
 [heading Header]
 
     #include <boost/fusion/support/category_of.hpp>
+ #include <boost/fusion/include/category_of.hpp>
 
 [heading Example]
 
@@ -266,6 +270,7 @@
 [heading Header]
 
     #include <boost/fusion/support/deduce.hpp>
+ #include <boost/fusion/include/deduce.hpp>
 
 [heading Synopsis]
     namespace traits
@@ -309,6 +314,7 @@
 [heading Header]
 
     #include <boost/fusion/support/deduce_sequence.hpp>
+ #include <boost/fusion/include/deduce_sequence.hpp>
 
 [heading Synopsis]
     namespace traits
@@ -413,6 +419,7 @@
 [heading Header]
 
     #include <boost/fusion/support/pair.hpp>
+ #include <boost/fusion/include/pair.hpp>
 
 [heading Example]
 

Modified: trunk/libs/fusion/doc/view.qbk
==============================================================================
--- trunk/libs/fusion/doc/view.qbk (original)
+++ trunk/libs/fusion/doc/view.qbk 2007-11-06 06:40:27 EST (Tue, 06 Nov 2007)
@@ -11,6 +11,7 @@
 [heading Header]
 
     #include <boost/fusion/view.hpp>
+ #include <boost/fusion/include/view.hpp>
 
 [section single_view]
 
@@ -19,6 +20,7 @@
 [heading Header]
 
     #include <boost/fusion/view/single_view.hpp>
+ #include <boost/fusion/include/single_view.hpp>
 
 [heading Synopsis]
 
@@ -73,6 +75,7 @@
 [heading Header]
 
     #include <boost/fusion/view/filter_view.hpp>
+ #include <boost/fusion/include/filter_view.hpp>
 
 [heading Synopsis]
 
@@ -134,6 +137,7 @@
 [heading Header]
 
     #include <boost/fusion/view/iterator_range.hpp>
+ #include <boost/fusion/include/iterator_range.hpp>
 
 [heading Synopsis]
 
@@ -201,6 +205,7 @@
 [heading Header]
 
     #include <boost/fusion/view/joint_view.hpp>
+ #include <boost/fusion/include/joint_view.hpp>
 
 [heading Synopsis]
 
@@ -260,6 +265,7 @@
 [heading Header]
 
     #include <boost/fusion/view/zip_view.hpp>
+ #include <boost/fusion/include/zip_view.hpp>
 
 [heading Synopsis]
 
@@ -319,6 +325,7 @@
 [heading Header]
 
     #include <boost/fusion/view/transform_view.hpp>
+ #include <boost/fusion/include/transform_view.hpp>
 
 [heading Synopsis]
 
@@ -413,6 +420,7 @@
 [heading Header]
 
     #include <boost/fusion/view/reverse_view.hpp>
+ #include <boost/fusion/include/reverse_view.hpp>
 
 [heading Synopsis]
 


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk