|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r70755 - in branches/pplib/variadics/boost/preprocessor: facilities variadic/detail
From: eldiener_at_[hidden]
Date: 2011-03-30 14:32:11
Author: eldiener
Date: 2011-03-30 14:32:10 EDT (Wed, 30 Mar 2011)
New Revision: 70755
URL: http://svn.boost.org/trac/boost/changeset/70755
Log:
Use own renamed version of BOOST_PP_CAT internally to avoid recursion.
Added:
branches/pplib/variadics/boost/preprocessor/variadic/detail/vd_cat.hpp (contents, props changed)
Text files modified:
branches/pplib/variadics/boost/preprocessor/facilities/overload.hpp | 17 +++++++++++++++--
branches/pplib/variadics/boost/preprocessor/variadic/detail/elem.hpp | 4 ++--
branches/pplib/variadics/boost/preprocessor/variadic/detail/size.hpp | 4 ++--
3 files changed, 19 insertions(+), 6 deletions(-)
Modified: branches/pplib/variadics/boost/preprocessor/facilities/overload.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/facilities/overload.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/facilities/overload.hpp 2011-03-30 14:32:10 EDT (Wed, 30 Mar 2011)
@@ -16,14 +16,27 @@
#
#if BOOST_PP_VARIADICS
#
-# include <boost/preprocessor/cat.hpp>
# include <boost/preprocessor/variadic/size.hpp>
#
# /* BOOST_PP_OVERLOAD */
#
#define BOOST_PP_OVERLOAD(prefix, ...) \
- BOOST_PP_CAT(prefix, BOOST_PP_VARIADIC_SIZE(__VA_ARGS__)) \
+ BOOST_PP_OV_CAT(prefix, BOOST_PP_VARIADIC_SIZE(__VA_ARGS__)) \
/**/
#
+# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC()
+# define BOOST_PP_OV_CAT(a, b) BOOST_PP_OV_CAT_I(a, b)
+# else
+# define BOOST_PP_OV_CAT(a, b) BOOST_PP_OV_CAT_OO((a, b))
+# define BOOST_PP_OV_CAT_OO(par) BOOST_PP_OV_CAT_I ## par
+# endif
+#
+# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
+# define BOOST_PP_OV_CAT_I(a, b) a ## b
+# else
+# define BOOST_PP_OV_CAT_I(a, b) BOOST_PP_OV_CAT_II(a ## b)
+# define BOOST_PP_OV_CAT_II(res) res
+# endif
+#
#endif // BOOST_PP_VARIADICS
#endif // BOOST_PREPROCESSOR_FACILITIES_OVERLOAD_HPP
Modified: branches/pplib/variadics/boost/preprocessor/variadic/detail/elem.hpp
==============================================================================
--- branches/pplib/variadics/boost/preprocessor/variadic/detail/elem.hpp (original)
+++ branches/pplib/variadics/boost/preprocessor/variadic/detail/elem.hpp 2011-03-30 14:32:10 EDT (Wed, 30 Mar 2011)
@@ -19,7 +19,7 @@
# include <boost/preprocessor/config/config.hpp>
#
# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
-# include <boost/preprocessor/cat.hpp>
+# include <boost/preprocessor/variadic/detail/vd_cat.hpp>
# include <boost/preprocessor/facilities/empty.hpp>
# endif
#
@@ -92,7 +92,7 @@
#define BOOST_PP_VARIADIC_DETAIL_PRIMITIVE_CAT(a, ...) a ## __VA_ARGS__
# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
#define BOOST_PP_VARIADIC_DETAIL_DATA_ELEM(n,...) \
- BOOST_PP_CAT(BOOST_PP_VARIADIC_DETAIL_CAT(BOOST_PP_VARIADIC_DETAIL_DATA_ELEM_, n)(__VA_ARGS__,),BOOST_PP_EMPTY()) \
+ BOOST_PP_VD_CAT(BOOST_PP_VARIADIC_DETAIL_CAT(BOOST_PP_VARIADIC_DETAIL_DATA_ELEM_, n)(__VA_ARGS__,),BOOST_PP_EMPTY()) \
/**/
#else
#define BOOST_PP_VARIADIC_DETAIL_DATA_ELEM(n,...) \
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-30 14:32:10 EDT (Wed, 30 Mar 2011)
@@ -20,7 +20,7 @@
# include <boost/preprocessor/variadic/detail/apply_var.hpp>
#
# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
-# include <boost/preprocessor/cat.hpp>
+# include <boost/preprocessor/variadic/detail/vd_cat.hpp>
# include <boost/preprocessor/facilities/empty.hpp>
# endif
#
@@ -36,7 +36,7 @@
/**/
# if BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
#define BOOST_PP_VARIADIC_DETAIL_SIZE(...) \
- 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()) \
+ BOOST_PP_VD_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(...) \
Added: branches/pplib/variadics/boost/preprocessor/variadic/detail/vd_cat.hpp
==============================================================================
--- (empty file)
+++ branches/pplib/variadics/boost/preprocessor/variadic/detail/vd_cat.hpp 2011-03-30 14:32:10 EDT (Wed, 30 Mar 2011)
@@ -0,0 +1,33 @@
+# /* **************************************************************************
+# * *
+# * (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_VD_CAT_HPP
+# define BOOST_PREPROCESSOR_VARIADIC_DETAIL_VD_CAT_HPP
+#
+# include <boost/preprocessor/config/config.hpp>
+#
+# /* BOOST_PP_VD_CAT */
+#
+# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MWCC()
+# define BOOST_PP_VD_CAT(a, b) BOOST_PP_VD_CAT_I(a, b)
+# else
+# define BOOST_PP_VD_CAT(a, b) BOOST_PP_VD_CAT_OO((a, b))
+# define BOOST_PP_VD_CAT_OO(par) BOOST_PP_VD_CAT_I ## par
+# endif
+#
+# if ~BOOST_PP_CONFIG_FLAGS() & BOOST_PP_CONFIG_MSVC()
+# define BOOST_PP_VD_CAT_I(a, b) a ## b
+# else
+# define BOOST_PP_VD_CAT_I(a, b) BOOST_PP_VD_CAT_II(a ## b)
+# define BOOST_PP_VD_CAT_II(res) res
+# endif
+#
+#endif // BOOST_PREPROCESSOR_VARIADIC_DETAIL_VD_CAT_HPP
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