From 293c471a6d49a1d8c8314def74d09f43f038691f Mon Sep 17 00:00:00 2001 From: Aleksey Gurtovoy Date: Fri, 7 Mar 2003 11:38:59 +0000 Subject: [PATCH] restore an old revision for SGI MIPSpro C++ [SVN r17757] --- include/boost/mpl/aux_/lambda_support.hpp | 27 ++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/include/boost/mpl/aux_/lambda_support.hpp b/include/boost/mpl/aux_/lambda_support.hpp index 6b72ce9..0a174da 100644 --- a/include/boost/mpl/aux_/lambda_support.hpp +++ b/include/boost/mpl/aux_/lambda_support.hpp @@ -26,6 +26,7 @@ #else +# include "boost/mpl/aux_/config/workaround.hpp" # include "boost/mpl/aux_/preprocessor/params.hpp" # include "boost/preprocessor/tuple/to_list.hpp" # include "boost/preprocessor/list/for_each_i.hpp" @@ -36,10 +37,34 @@ typedef_ param BOOST_PP_CAT(arg,BOOST_PP_INC(i)); \ /**/ +// agurt, 07/mar/03: restore an old revision for the sake of SGI MIPSpro C++ +#if BOOST_WORKAROUND(__EDG_VERSION__, <= 238) + +# define BOOST_MPL_AUX_LAMBDA_SUPPORT(i, name, params) \ + BOOST_STATIC_CONSTANT(int, arity = i); \ + BOOST_PP_LIST_FOR_EACH_I_R( \ + 1 \ + , BOOST_MPL_AUX_LAMBDA_SUPPORT_ARG_TYPEDEF_FUNC \ + , typedef \ + , BOOST_PP_TUPLE_TO_LIST(i,params) \ + ) \ + struct rebind \ + { \ + template< BOOST_MPL_PP_PARAMS(i,typename U) > struct apply \ + : name< BOOST_MPL_PP_PARAMS(i,U) > \ + { \ + }; \ + }; \ + /**/ + +# define BOOST_MPL_AUX_LAMBDA_SUPPORT_SPEC(i, name, params) \ + BOOST_MPL_AUX_LAMBDA_SUPPORT(i, name, params) \ + /**/ + +#elif BOOST_WORKAROUND(__EDG_VERSION__, <= 244) && !defined(BOOST_INTEL_CXX_VERSION) // agurt, 18/jan/03: old EDG-based compilers actually enforce 11.4 para 9 // (in strict mode), so we have to provide an alternative to the // MSVC-optimized implementation -#if defined(__EDG_VERSION__) && !defined(BOOST_INTEL_CXX_VERSION) # define BOOST_MPL_AUX_LAMBDA_SUPPORT_SPEC(i, name, params) \ BOOST_STATIC_CONSTANT(int, arity = i); \