On 3/25/2017 8:30 AM, Peter Dimov via Boost wrote:
Paul A. Bristow wrote:
In file included from I:\modular-boost\boost/mpl/next.hpp:17: I:\modular-boost\boost/mpl/next_prior.hpp:44:23: error: too many arguments provided to function-like macro invocation BOOST_MPL_AUX_NA_SPEC(1, next) ^
I tried to compile
#include
#include int main() { namespace mpl = boost::mpl;
using L = mpl::list<>; using L2 = mpl::push_front
; } with the build-in Clang/C2, hit
1>../boost-git/boost\boost/mpl/next_prior.hpp(44,1): error : pasting formed 'BOOST_PP_TUPLE_ELEM_O_3(', an invalid preprocessing token [-Winvalid-token-paste] 1>BOOST_MPL_AUX_NA_SPEC(1, next)
Tried
#define BOOST_PP_CONFIG_FLAGS() 1
at the top, same. The "strict" PP configuration is used, it just doesn't work for some reason I couldn't figure out. It's possible that -fms-extensions also changes the preprocessor and this breaks PP, but without it, MS's headers don't compile.
There is also BOOST_PP_VARIADICS_MSVC, which provides lots of special VC++ variadics workarounds.
If you tell MPL to not use PP though:
#include
#undef BOOST_MPL_CFG_NO_OWN_PP_PRIMITIVES this simple example works. I've no idea whether more complex ones will.
But if you don't insist on an MS-compatible Clang and can stomach the old and busted 3.9, you can just use the Cygwin Clang. That's what I do.