Workarounds for Fusion on IBM xlc

[SVN r40766]
This commit is contained in:
Joel de Guzman
2007-11-05 02:10:42 +00:00
parent b9ab685b44
commit 1c5bc499a7
16 changed files with 99 additions and 0 deletions

View File

@ -22,7 +22,11 @@ namespace boost { namespace fusion
};
template <typename Sequence, typename F>
#if defined(BOOST_PARTIAL_SPECIALIZATION_EXPLICT_ARGS)
struct transform<Sequence, F, void_>
#else
struct transform<Sequence, F>
#endif
{
typedef transform_view<Sequence, F> type;
};

View File

@ -17,6 +17,7 @@
#include <boost/preprocessor/repetition/enum.hpp>
#include <boost/preprocessor/repetition/enum_params.hpp>
#include <boost/preprocessor/repetition/enum_binary_params.hpp>
#include <boost/preprocessor/repetition/repeat_from_to.hpp>
#include <boost/preprocessor/arithmetic/inc.hpp>
#include <boost/preprocessor/iteration/iterate.hpp>
#include <boost/mpl/vector.hpp>
@ -53,7 +54,13 @@ namespace boost { namespace fusion {
namespace result_of
{
template< BOOST_PP_ENUM_PARAMS(ZIP_ITERATION, typename T) >
#if defined(BOOST_PARTIAL_SPECIALIZATION_EXPLICT_ARGS)
#define TEXT(z, n, text) , text
struct zip< BOOST_PP_ENUM_PARAMS(ZIP_ITERATION, T) BOOST_PP_REPEAT_FROM_TO(BOOST_PP_DEC(ZIP_ITERATION), FUSION_MAX_ZIP_SEQUENCES, TEXT, void_) >
#undef TEXT
#else
struct zip< BOOST_PP_ENUM_PARAMS(ZIP_ITERATION, T) >
#endif
{
typedef mpl::vector< BOOST_PP_ENUM_PARAMS(ZIP_ITERATION, T) > sequences;
typedef typename mpl::transform<sequences, add_reference<mpl::_> >::type ref_params;