Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r66860 - in sandbox/statistics/support/boost/assign/v2: put/compose/functor temporary
From: erwann.rogard_at_[hidden]
Date: 2010-11-29 18:06:42


Author: e_r
Date: 2010-11-29 18:06:40 EST (Mon, 29 Nov 2010)
New Revision: 66860
URL: http://svn.boost.org/trac/boost/changeset/66860

Log:
minor reorganization to boost/assign/v2
Added:
   sandbox/statistics/support/boost/assign/v2/temporary/variadic_args_to_indices.hpp (contents, props changed)
Text files modified:
   sandbox/statistics/support/boost/assign/v2/put/compose/functor/forward_args.hpp | 2 +-
   1 files changed, 1 insertions(+), 1 deletions(-)

Modified: sandbox/statistics/support/boost/assign/v2/put/compose/functor/forward_args.hpp
==============================================================================
--- sandbox/statistics/support/boost/assign/v2/put/compose/functor/forward_args.hpp (original)
+++ sandbox/statistics/support/boost/assign/v2/put/compose/functor/forward_args.hpp 2010-11-29 18:06:40 EST (Mon, 29 Nov 2010)
@@ -20,7 +20,7 @@
 #if BOOST_ASSIGN_V2_ENABLE_CPP0X
 #include <utility>
 // TODO eventually replace by mpl/variadic_template/package_range_c.hpp>
-#include <boost/mpl/detail/variadic_args_to_indices.hpp>
+#include <boost/assign/v2/temporary/variadic_args_to_indices.hpp>
 #else
 #include <boost/preprocessor/arithmetic/inc.hpp>
 #include <boost/preprocessor/control/expr_if.hpp>

Added: sandbox/statistics/support/boost/assign/v2/temporary/variadic_args_to_indices.hpp
==============================================================================
--- (empty file)
+++ sandbox/statistics/support/boost/assign/v2/temporary/variadic_args_to_indices.hpp 2010-11-29 18:06:40 EST (Mon, 29 Nov 2010)
@@ -0,0 +1,52 @@
+#ifndef BOOST_MPL_DETAIL_VARIADIC_ARGS_TO_INDICES_HPP_ER_2010
+#define BOOST_MPL_DETAIL_VARIADIC_ARGS_TO_INDICES_HPP_ER_2010
+
+// Provided temporarily, until /variadic_template/package_range_c.hpp by
+// Larry Evans is fully supported in the release.
+// Source : http://groups.google.com/group/comp.lang.c++/browse_thread/thread/b21c20c4312c383f/3b842a03167f5bd9#3b842a03167f5bd9
+
+namespace boost{
+namespace mpl{
+namespace er2010{
+
+template<typename I, I...Values> struct indices{};
+
+namespace impl{
+
+template<typename ...Args> struct pack_holder{};
+
+template<typename Indices,typename Pack> struct args_to_indices{};
+
+template<typename I, I...Tail, typename T, typename... Rest>
+struct args_to_indices<
+ indices<I, Tail...>,
+ impl::pack_holder<T, Rest...>
+>
+{
+ typedef typename impl::args_to_indices<
+ indices<I, Tail..., sizeof...(Tail)>,
+ pack_holder<Rest...>
+ >::type type;
+};
+
+template<typename I, I...Tail>
+struct args_to_indices<
+ indices<I, Tail...>,
+ pack_holder<>
+>{
+ typedef indices<I, Tail...> type;
+};
+
+}// impl
+
+template<typename I,typename...Args>
+struct args_to_indices : impl::args_to_indices<
+ indices<I>,
+ impl::pack_holder<Args...>
+>{};
+
+}// er2010
+}// mpl
+}// boost
+
+#endif // BOOST_MPL_DETAIL_VARIADIC_ARGS_TO_INDICES_HPP_ER_2010


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