|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r70705 - in branches/pplib/variadics: boost/preprocessor/config boost/preprocessor/tuple boost/preprocessor/tuple/detail boost/preprocessor/variadic/detail libs/preprocessor/test
From: eldiener_at_[hidden]
Date: 2011-03-29 16:48:54
Author: eldiener
Date: 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
New Revision: 70705
URL: http://svn.boost.org/trac/boost/changeset/70705
Log:
Changes to correct compiler errors.
Added:
branches/pplib/variadics/boost/preprocessor/tuple/detail/
branches/pplib/variadics/boost/preprocessor/tuple/detail/use_overload.hpp (contents, props changed)
branches/pplib/variadics/boost/preprocessor/variadic/detail/apply_var.hpp (contents, props changed)
Text files modified:
branches/pplib/variadics/boost/preprocessor/config/variadics.hpp | 8 ++++----
branches/pplib/variadics/boost/preprocessor/tuple/eat.hpp | 18 ++++++++++--------
branches/pplib/variadics/boost/preprocessor/tuple/elem.hpp | 25 +++++++++++++------------
branches/pplib/variadics/boost/preprocessor/tuple/enum.hpp | 15 ++-------------
branches/pplib/variadics/boost/preprocessor/tuple/rem.hpp | 28 ++++++++++++++++------------
branches/pplib/variadics/boost/preprocessor/tuple/reverse.hpp | 6 +++---
branches/pplib/variadics/boost/preprocessor/tuple/size.hpp | 4 +++-
branches/pplib/variadics/boost/preprocessor/tuple/to_array.hpp | 4 ++--
branches/pplib/variadics/boost/preprocessor/tuple/to_list.hpp | 6 +++---
branches/pplib/variadics/boost/preprocessor/tuple/to_seq.hpp | 6 +++---
branches/pplib/variadics/boost/preprocessor/variadic/detail/size.hpp | 26 +++++++-------------------
branches/pplib/variadics/libs/preprocessor/test/Jamfile.v2 | 18 ++++++++++++++++--
12 files changed, 82 insertions(+), 82 deletions(-)
Modified: branches/pplib/variadics/boost/preprocessor/config/variadics.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/config/variadics.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/config/variadics.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -12,16 +12,16 @@
# ifndef BOOST_PREPROCESSOR_CONFIG_VARIADICS_HPP
# define BOOST_PREPROCESSOR_CONFIG_VARIADICS_HPP
#
-# if defined(BOOST_PP_NO_VARIADICS)
+# if defined(BOOST_PP_TEST_NO_VARIADICS)
/* This macro is purely for testing purposes so that we can
test Boost PP without variadic macro support even on
compilers that support variadic macros by defining
- BOOST_PP_NO_VARIADICS on the command line. We can remove
+ BOOST_PP_TEST_NO_VARIADICS on the command line. We can remove
this after the intiial tests.
*/
# define BOOST_PP_VARIADICS 0
#
-# else // !defined(BOOST_PP_NO_VARIADICS)
+# else // !defined(BOOST_PP_TEST_NO_VARIADICS)
#
# if 1
/* This is the code we will use. It is essentially a duplication
@@ -163,6 +163,6 @@
#
# endif // 1
#
-# endif // BOOST_PP_NO_VARIADICS
+# endif // BOOST_PP_TEST_NO_VARIADICS
#
# endif // BOOST_PREPROCESSOR_CONFIG_VARIADICS_HPP
Added: branches/pplib/variadics/boost/preprocessor/tuple/detail/use_overload.hpp
==============================================================================
--- (empty file)
+++ branches/pplib/variadics/boost/preprocessor/tuple/detail/use_overload.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -0,0 +1,29 @@
+# /* **************************************************************************
+# * *
+# * (C) Copyright Edward Diener 2011.
+# * Distributed under the Boost Software License, Version 1.0. (See
+# * accompanying file LICENSE_1_0.txt or copy at
+# * http://www.boost.org/LICENSE_1_0.txt)
+# * *
+# ************************************************************************** */
+#
+# /* See http://www.boost.org for most recent version. */
+#
+# ifndef BOOST_PREPROCESSOR_TUPLE_USE_OVERLOAD_HPP
+# define BOOST_PREPROCESSOR_TUPLE_USE_OVERLOAD_HPP
+#
+# include <boost/preprocessor/config/variadics.hpp>
+#
+# if BOOST_PP_VARIADICS
+#
+# include <boost/preprocessor/facilities/overload.hpp>
+# include <boost/preprocessor/variadic/detail/apply_var.hpp>
+#
+# /* BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD */
+#
+# define BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD(prefix,...) \
+ BOOST_PP_VARIADIC_DETAIL_APPLY_VAR(BOOST_PP_OVERLOAD(prefix, __VA_ARGS__),(__VA_ARGS__)) \
+ /**/
+#
+# endif // BOOST_PP_VARIADICS
+# endif // BOOST_PREPROCESSOR_TUPLE_USE_OVERLOAD_HPP
Modified: branches/pplib/variadics/boost/preprocessor/tuple/eat.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/eat.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/eat.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -14,25 +14,28 @@
# ifndef BOOST_PREPROCESSOR_TUPLE_EAT_HPP
# define BOOST_PREPROCESSOR_TUPLE_EAT_HPP
#
+# include <boost/preprocessor/config/config.hpp>
# include <boost/preprocessor/config/variadics.hpp>
#
-# if BOOST_PP_VARIADICS
+# if BOOST_PP_VARIADICS && !defined(BOOST_PP_TEST_NO_TUPLE_EAT)
#
# /* BOOST_PP_TUPLE_EAT */
#
-#define BOOST_PP_TUPLE_EAT(size) BOOST_PP_DETAIL_TUPLE_EAT
-#define BOOST_PP_DETAIL_TUPLE_EAT(...)
+#define BOOST_PP_TUPLE_EAT(size) BOOST_PP_TUPLE_EAT_DETAIL
+#define BOOST_PP_TUPLE_EAT_DETAIL(...)
#
# else
#
-# include <boost/preprocessor/config/config.hpp>
-#
# /* BOOST_PP_TUPLE_EAT */
#
+# define BOOST_PP_TUPLE_EAT(size) BOOST_PP_TUPLE_EAT_COMMON(size)
+#
+# endif // BOOST_PP_VARIADICS
+#
# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC()
-# define BOOST_PP_TUPLE_EAT(size) BOOST_PP_TUPLE_EAT_I(size)
+# define BOOST_PP_TUPLE_EAT_COMMON(size) BOOST_PP_TUPLE_EAT_I(size)
# else
-# define BOOST_PP_TUPLE_EAT(size) BOOST_PP_TUPLE_EAT_OO((size))
+# define BOOST_PP_TUPLE_EAT_COMMON(size) BOOST_PP_TUPLE_EAT_OO((size))
# define BOOST_PP_TUPLE_EAT_OO(par) BOOST_PP_TUPLE_EAT_I ## par
# endif
#
@@ -66,4 +69,3 @@
# define BOOST_PP_TUPLE_EAT_25(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y)
#
# endif
-# endif
Modified: branches/pplib/variadics/boost/preprocessor/tuple/elem.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/elem.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/elem.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -14,36 +14,38 @@
# ifndef BOOST_PREPROCESSOR_TUPLE_ELEM_HPP
# define BOOST_PREPROCESSOR_TUPLE_ELEM_HPP
#
+# include <boost/preprocessor/config/config.hpp>
# include <boost/preprocessor/config/variadics.hpp>
#
-# if BOOST_PP_VARIADICS
+# if BOOST_PP_VARIADICS && !defined(BOOST_PP_TEST_NO_TUPLE_ELEM)
#
-# include <boost/preprocessor/facilities/overload.hpp>
-# include <boost/preprocessor/tuple/enum.hpp>
-# include <boost/preprocessor/variadic/elem.hpp>
+# include <boost/preprocessor/tuple/size.hpp>
+# include "detail/use_overload.hpp"
#
# /* BOOST_PP_TUPLE_ELEM */
#
# define BOOST_PP_TUPLE_ELEM(...) \
- BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_DETAIL_ELEM_, __VA_ARGS__)(__VA_ARGS__) \
+ BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD(BOOST_PP_TUPLE_DETAIL_ELEM_,__VA_ARGS__) \
/**/
# define BOOST_PP_TUPLE_DETAIL_ELEM_2(i, tuple) \
- BOOST_PP_VARIADIC_ELEM(i,BOOST_PP_TUPLE_ENUM(tuple)) \
+ BOOST_PP_TUPLE_DETAIL_ELEM_3(BOOST_PP_TUPLE_SIZE(tuple),i,tuple) \
/**/
# define BOOST_PP_TUPLE_DETAIL_ELEM_3(size, i, tuple) \
- BOOST_PP_TUPLE_DETAIL_ELEM_2(i, tuple) \
+ BOOST_PP_TUPLE_ELEM_COMMON(size, i, tuple) \
/**/
#
# else
#
-# include <boost/preprocessor/config/config.hpp>
-#
# /* BOOST_PP_TUPLE_ELEM */
#
+# define BOOST_PP_TUPLE_ELEM(size, index, tuple) BOOST_PP_TUPLE_ELEM_COMMON(size, index, tuple)
+#
+# endif // BOOST_PP_VARIADICS
+#
# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC()
-# define BOOST_PP_TUPLE_ELEM(size, index, tuple) BOOST_PP_TUPLE_ELEM_I(size, index, tuple)
+# define BOOST_PP_TUPLE_ELEM_COMMON(size, index, tuple) BOOST_PP_TUPLE_ELEM_I(size, index, tuple)
# else
-# define BOOST_PP_TUPLE_ELEM(size, index, tuple) BOOST_PP_TUPLE_ELEM_OO((size, index, tuple))
+# define BOOST_PP_TUPLE_ELEM_COMMON(size, index, tuple) BOOST_PP_TUPLE_ELEM_OO((size, index, tuple))
# define BOOST_PP_TUPLE_ELEM_OO(par) BOOST_PP_TUPLE_ELEM_I ## par
# endif
#
@@ -406,5 +408,4 @@
# define BOOST_PP_TUPLE_ELEM_25_23(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y) x
# define BOOST_PP_TUPLE_ELEM_25_24(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y) y
#
-# endif // BOOST_PP_VARIADICS
# endif
Modified: branches/pplib/variadics/boost/preprocessor/tuple/enum.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/enum.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/enum.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -13,29 +13,18 @@
# define BOOST_PREPROCESSOR_TUPLE_ENUM_HPP
#
# include <boost/preprocessor/config/variadics.hpp>
+# include <boost/preprocessor/tuple/rem.hpp>
#
#if BOOST_PP_VARIADICS
#
-# include <boost/preprocessor/facilities/overload.hpp>
-#
# /* BOOST_PP_TUPLE_ENUM */
#
#define BOOST_PP_TUPLE_ENUM(...) \
- BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_ENUM_, __VA_ARGS__)(__VA_ARGS__) \
-/**/
-#define BOOST_PP_TUPLE_ENUM_1(tuple) \
- BOOST_PP_TUPLE_DETAIL_ENUM(tuple) \
+ BOOST_PP_TUPLE_REM_CTOR(__VA_ARGS__) \
/**/
-#define BOOST_PP_TUPLE_ENUM_2(size, tuple) \
- BOOST_PP_TUPLE_ENUM_1(tuple) \
-/**/
-#define BOOST_PP_TUPLE_DETAIL_REMOVE_TUPLE_PARENS(...) __VA_ARGS__
-#define BOOST_PP_TUPLE_DETAIL_ENUM(tuple) BOOST_PP_TUPLE_DETAIL_REMOVE_TUPLE_PARENS tuple
#
#else
#
-#include <boost/preprocessor/tuple/rem.hpp>
-#
# /* BOOST_PP_TUPLE_ENUM */
#
#define BOOST_PP_TUPLE_ENUM(size, tuple) \
Modified: branches/pplib/variadics/boost/preprocessor/tuple/rem.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/rem.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/rem.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -12,11 +12,12 @@
# ifndef BOOST_PREPROCESSOR_TUPLE_REM_HPP
# define BOOST_PREPROCESSOR_TUPLE_REM_HPP
#
+# include <boost/preprocessor/config/config.hpp>
# include <boost/preprocessor/config/variadics.hpp>
#
-# if BOOST_PP_VARIADICS
+# if BOOST_PP_VARIADICS && !defined(BOOST_PP_TEST_NO_TUPLE_REM)
#
-# include <boost/preprocessor/facilities/overload.hpp>
+# include "detail/use_overload.hpp"
#
# /* BOOST_PP_TUPLE_REM */
#
@@ -26,21 +27,27 @@
# /* BOOST_PP_TUPLE_REM_CTOR */
#
# define BOOST_PP_TUPLE_REM_CTOR(...) \
- BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_DETAIL_REM_CTOR_, __VA_ARGS__)(__VA_ARGS__) \
+ BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD(BOOST_PP_TUPLE_DETAIL_REM_CTOR_, __VA_ARGS__) \
/**/
# define BOOST_PP_TUPLE_DETAIL_REM_CTOR_1(tuple) BOOST_PP_DETAIL_TUPLE_REM tuple
# define BOOST_PP_TUPLE_DETAIL_REM_CTOR_2(size, tuple) BOOST_PP_TUPLE_DETAIL_REM_CTOR_1(tuple)
#
# else
#
-# include <boost/preprocessor/config/config.hpp>
-#
# /* BOOST_PP_TUPLE_REM */
#
+# define BOOST_PP_TUPLE_REM(size) BOOST_PP_TUPLE_REM_COMMON(size)
+#
+# /* BOOST_PP_TUPLE_REM_CTOR */
+#
+# define BOOST_PP_TUPLE_REM_CTOR(size, tuple) BOOST_PP_TUPLE_REM_CTOR_COMMON(size, tuple)
+#
+# endif // BOOST_PP_VARIADICS
+#
# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC()
-# define BOOST_PP_TUPLE_REM(size) BOOST_PP_TUPLE_REM_I(size)
+# define BOOST_PP_TUPLE_REM_COMMON(size) BOOST_PP_TUPLE_REM_I(size)
# else
-# define BOOST_PP_TUPLE_REM(size) BOOST_PP_TUPLE_REM_OO((size))
+# define BOOST_PP_TUPLE_REM_COMMON(size) BOOST_PP_TUPLE_REM_OO((size))
# define BOOST_PP_TUPLE_REM_OO(par) BOOST_PP_TUPLE_REM_I ## par
# endif
#
@@ -73,12 +80,10 @@
# define BOOST_PP_TUPLE_REM_24(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x) a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x
# define BOOST_PP_TUPLE_REM_25(a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y) a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p, q, r, s, t, u, v, w, x, y
#
-# /* BOOST_PP_TUPLE_REM_CTOR */
-#
# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_EDG()
-# define BOOST_PP_TUPLE_REM_CTOR(size, tuple) BOOST_PP_TUPLE_REM_CTOR_I(BOOST_PP_TUPLE_REM(size), tuple)
+# define BOOST_PP_TUPLE_REM_CTOR_COMMON(size, tuple) BOOST_PP_TUPLE_REM_CTOR_I(BOOST_PP_TUPLE_REM(size), tuple)
# else
-# define BOOST_PP_TUPLE_REM_CTOR(size, tuple) BOOST_PP_TUPLE_REM_CTOR_D(size, tuple)
+# define BOOST_PP_TUPLE_REM_CTOR_COMMON(size, tuple) BOOST_PP_TUPLE_REM_CTOR_D(size, tuple)
# define BOOST_PP_TUPLE_REM_CTOR_D(size, tuple) BOOST_PP_TUPLE_REM_CTOR_I(BOOST_PP_TUPLE_REM(size), tuple)
# endif
#
@@ -91,4 +96,3 @@
# endif
#
# endif
-# endif
Modified: branches/pplib/variadics/boost/preprocessor/tuple/reverse.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/reverse.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/reverse.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -17,15 +17,15 @@
# include <boost/preprocessor/config/config.hpp>
# include <boost/preprocessor/config/variadics.hpp>
#
-# if BOOST_PP_VARIADICS
+# if BOOST_PP_VARIADICS && !defined(BOOST_PP_TEST_NO_TUPLE_REVERSE)
#
-# include <boost/preprocessor/facilities/overload.hpp>
# include <boost/preprocessor/tuple/size.hpp>
+# include "detail/use_overload.hpp"
#
# /* BOOST_PP_TUPLE_REVERSE */
#
# define BOOST_PP_TUPLE_REVERSE(...) \
- BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_DETAIL_REVERSE_, __VA_ARGS__)(__VA_ARGS__) \
+ BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD(BOOST_PP_TUPLE_DETAIL_REVERSE_, __VA_ARGS__) \
/**/
# define BOOST_PP_TUPLE_DETAIL_REVERSE_1(tuple) \
BOOST_PP_TUPLE_DETAIL_REVERSE_2(BOOST_PP_TUPLE_SIZE(tuple),tuple) \
Modified: branches/pplib/variadics/boost/preprocessor/tuple/size.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/size.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/size.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -16,11 +16,13 @@
#
#if BOOST_PP_VARIADICS
#
+# include <boost/preprocessor/tuple/enum.hpp>
# include <boost/preprocessor/variadic/size.hpp>
#
# /* BOOST_PP_TUPLE_SIZE */
#
-#define BOOST_PP_TUPLE_SIZE(tuple) BOOST_PP_VARIADIC_SIZE tuple
+#define BOOST_PP_TUPLE_SIZE(tuple) BOOST_PP_TUPLE_SIZE_DETAIL(tuple)
+#define BOOST_PP_TUPLE_SIZE_DETAIL(tuple) BOOST_PP_VARIADIC_SIZE(BOOST_PP_TUPLE_ENUM(tuple))
#
#endif // BOOST_PP_VARIADICS
#endif // BOOST_PREPROCESSOR_TUPLE_SIZE_HPP
Modified: branches/pplib/variadics/boost/preprocessor/tuple/to_array.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/to_array.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/to_array.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -16,13 +16,13 @@
#
#if BOOST_PP_VARIADICS
#
-# include <boost/preprocessor/facilities/overload.hpp>
# include <boost/preprocessor/tuple/size.hpp>
+# include "detail/use_overload.hpp"
#
# /* BOOST_PP_TUPLE_TO_ARRAY */
#
# define BOOST_PP_TUPLE_TO_ARRAY(...) \
- BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_DETAIL_TO_ARRAY_, __VA_ARGS__)(__VA_ARGS__) \
+ BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD(BOOST_PP_TUPLE_DETAIL_TO_ARRAY_, __VA_ARGS__) \
/**/
# define BOOST_PP_TUPLE_DETAIL_TO_ARRAY_1(tuple) \
BOOST_PP_TUPLE_DETAIL_TO_ARRAY_2(BOOST_PP_TUPLE_SIZE(tuple),tuple) \
Modified: branches/pplib/variadics/boost/preprocessor/tuple/to_list.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/to_list.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/to_list.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -17,15 +17,15 @@
# include <boost/preprocessor/config/config.hpp>
# include <boost/preprocessor/config/variadics.hpp>
#
-# if BOOST_PP_VARIADICS
+# if BOOST_PP_VARIADICS && !defined(BOOST_PP_TEST_NO_TUPLE_TO_LIST)
#
-# include <boost/preprocessor/facilities/overload.hpp>
# include <boost/preprocessor/tuple/size.hpp>
+# include "detail/use_overload.hpp"
#
# /* BOOST_PP_TUPLE_TO_LIST */
#
# define BOOST_PP_TUPLE_TO_LIST(...) \
- BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_DETAIL_TO_LIST_, __VA_ARGS__)(__VA_ARGS__) \
+ BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD(BOOST_PP_TUPLE_DETAIL_TO_LIST_, __VA_ARGS__) \
/**/
# define BOOST_PP_TUPLE_DETAIL_TO_LIST_1(tuple) \
BOOST_PP_TUPLE_DETAIL_TO_LIST_2(BOOST_PP_TUPLE_SIZE(tuple),tuple) \
Modified: branches/pplib/variadics/boost/preprocessor/tuple/to_seq.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/tuple/to_seq.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/tuple/to_seq.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -15,15 +15,15 @@
# include <boost/preprocessor/config/config.hpp>
# include <boost/preprocessor/config/variadics.hpp>
#
-# if BOOST_PP_VARIADICS
+# if BOOST_PP_VARIADICS && !defined(BOOST_PP_TEST_NO_TUPLE_TO_SEQ)
#
-# include <boost/preprocessor/facilities/overload.hpp>
# include <boost/preprocessor/tuple/size.hpp>
+# include "detail/use_overload.hpp"
#
# /* BOOST_PP_TUPLE_TO_SEQ */
#
# define BOOST_PP_TUPLE_TO_SEQ(...) \
- BOOST_PP_OVERLOAD(BOOST_PP_TUPLE_DETAIL_TO_SEQ_, __VA_ARGS__)(__VA_ARGS__) \
+ BOOST_PP_TUPLE_DETAIL_USE_OVERLOAD(BOOST_PP_TUPLE_DETAIL_TO_SEQ_, __VA_ARGS__) \
/**/
# define BOOST_PP_TUPLE_DETAIL_TO_SEQ_1(tuple) \
BOOST_PP_TUPLE_DETAIL_TO_SEQ_2(BOOST_PP_TUPLE_SIZE(tuple),tuple) \
Added: branches/pplib/variadics/boost/preprocessor/variadic/detail/apply_var.hpp
==============================================================================
--- (empty file)
+++ branches/pplib/variadics/boost/preprocessor/variadic/detail/apply_var.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -0,0 +1,22 @@
+# /* **************************************************************************
+# * *
+# * (C) Copyright Edward Diener 2011.
+# * Distributed under the Boost Software License, Version 1.0. (See
+# * accompanying file LICENSE_1_0.txt or copy at
+# * http://www.boost.org/LICENSE_1_0.txt)
+# * *
+# ************************************************************************** */
+#
+# /* See http://www.boost.org for most recent version. */
+#
+# ifndef BOOST_PREPROCESSOR_VARIADIC_DETAIL_APPLYVAR_HPP
+# define BOOST_PREPROCESSOR_VARIADIC_DETAIL_APPLYVAR_HPP
+#
+#define BOOST_PP_VARIADIC_DETAIL_APPLY_VAR_I(macro, args) \
+ macro args \
+/**/
+#define BOOST_PP_VARIADIC_DETAIL_APPLY_VAR(macro, args) \
+ BOOST_PP_VARIADIC_DETAIL_APPLY_VAR_I(macro, args) \
+/**/
+#
+#endif // BOOST_PREPROCESSOR_VARIADIC_DETAIL_APPLYVAR_HPP
Modified: branches/pplib/variadics/boost/preprocessor/variadic/detail/size.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/variadic/detail/size.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/variadic/detail/size.hpp 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -17,42 +17,30 @@
#if BOOST_PP_VARIADICS
#
# include <boost/preprocessor/config/config.hpp>
+# include "apply_var.hpp"
#
# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
-# include <boost/preprocessor/arithmetic/add.hpp>
+# include <boost/preprocessor/cat.hpp>
+# include <boost/preprocessor/facilities/empty.hpp>
# endif
#
#define BOOST_PP_VARIADIC_DETAIL_ARG_N( \
A1,A2,A3,A4,A5,A6,A7,A8,A9,A10, \
A11,A12,A13,A14,A15,A16,A17,A18,A19,A20, \
- A21,A22,A23,A24,A25,A26,A27,A28,A29,A30, \
- A31,A32,A33,A34,A35,A36,A37,A38,A39,A40, \
- A41,A42,A43,A44,A45,A46,A47,A48,A49,A50, \
- A51,A52,A53,A54,A55,A56,A57,A58,A59,A60, \
- A61,A62,A63,N,...) N \
+ A21,A22,A23,A24,N,...) N \
/**/
#define BOOST_PP_VARIADIC_DETAIL_RSEQ_N() \
- 63,62,61,60, \
- 59,58,57,56,55,54,53,52,51,50, \
- 49,48,47,46,45,44,43,42,41,40, \
- 39,38,37,36,35,34,33,32,31,30, \
- 29,28,27,26,25,24,23,22,21,20, \
+ 24,23,22,21,20, \
19,18,17,16,15,14,13,12,11,10, \
9,8,7,6,5,4,3,2,1,0 \
/**/
-#define BOOST_PP_VARIADIC_DETAIL_APPLY_I(macro, args) \
- macro args \
-/**/
-#define BOOST_PP_VARIADIC_DETAIL_APPLY(macro, args) \
- BOOST_PP_VARIADIC_DETAIL_APPLY_I(macro, args) \
-/**/
# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
#define BOOST_PP_VARIADIC_DETAIL_SIZE(...) \
- BOOST_PP_ADD(BOOST_PP_VARIADIC_DETAIL_APPLY(BOOST_PP_VARIADIC_DETAIL_ARG_N, (__VA_ARGS__, BOOST_PP_VARIADIC_DETAIL_RSEQ_N())),0) \
+ BOOST_PP_CAT(BOOST_PP_VARIADIC_DETAIL_APPLY_VAR(BOOST_PP_VARIADIC_DETAIL_ARG_N, (__VA_ARGS__, BOOST_PP_VARIADIC_DETAIL_RSEQ_N())),BOOST_PP_EMPTY()) \
/**/
#else
#define BOOST_PP_VARIADIC_DETAIL_SIZE(...) \
- BOOST_PP_VARIADIC_DETAIL_APPLY(BOOST_PP_VARIADIC_DETAIL_ARG_N, (__VA_ARGS__, BOOST_PP_VARIADIC_DETAIL_RSEQ_N())) \
+ BOOST_PP_VARIADIC_DETAIL_APPLY_VAR(BOOST_PP_VARIADIC_DETAIL_ARG_N, (__VA_ARGS__, BOOST_PP_VARIADIC_DETAIL_RSEQ_N())) \
/**/
#endif
#
Modified: branches/pplib/variadics/libs/preprocessor/test/Jamfile.v2
==============================================================================
--- branches/pplib/variadics/libs/preprocessor/test/Jamfile.v2 (original)
+++ branches/pplib/variadics/libs/preprocessor/test/Jamfile.v2 2011-03-29 16:48:52 EDT (Tue, 29 Mar 2011)
@@ -4,8 +4,22 @@
import testing ;
+project preprocessor_tests : requirements <warnings>on
+ <toolset>gcc-4.3.0:<warnings>all
+ <toolset>gcc-4.3.0:<cxxflags>-Wno-variadic-macros
+ <toolset>gcc-4.4.0:<warnings>all
+ <toolset>gcc-4.4.0:<cxxflags>-Wno-variadic-macros
+ <toolset>gcc-4.5.0:<warnings>all
+ <toolset>gcc-4.5.0:<cxxflags>-Wno-variadic-macros
+ <toolset>gcc-4.5.0:<linkflags>"-Wl,--enable-auto-import"
+ <toolset>gcc-4.5.2:<warnings>all
+ <toolset>gcc-4.5.2:<cxxflags>-Wno-variadic-macros
+ <toolset>msvc:<warnings>all
+ ;
+
test-suite preprocessor
- : [ compile arithmetic.cpp ]
+ :
+ [ compile arithmetic.cpp ]
[ compile array.cpp ]
[ compile comparison.cpp ]
[ compile control.cpp ]
@@ -19,4 +33,4 @@
[ compile seq.cpp ]
[ compile slot.cpp ]
[ compile tuple.cpp ]
- ;
+ ;
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