Boost logo

Boost :

From: Toon Knapen (toon.knapen_at_[hidden])
Date: 2004-09-06 06:37:20


Daniel James wrote:

>
> Daniel James wrote:
>
>> Sorry about all these tests and thanks for your patience. Here's
>> another one which uses a slightly different method that I think should
>> will better:
>
>
> Actually, can you also preprocess this test? I really think this one
> will work. Which probably means it won't.
>
> #include <boost/preprocessor/seq/elem.hpp>
> #include <boost/preprocessor/punctuation/paren.hpp>
>
> #define IS_NULLARY(x) BOOST_PP_SEQ_ELEM(1, (IS_NULLARY_C x)(0))
> #define IS_NULLARY_C() ~ BOOST_PP_RPAREN() (1) BOOST_PP_LPAREN() ~
>
> IS_NULLARY(()) // 1
> IS_NULLARY(()abc) // 1
> IS_NULLARY(+) // 0
> IS_NULLARY(xyz) // 0
>
> #define IS_UNARY(x) IS_NULLARY(IS_UNARY_C x)
> #define IS_UNARY_C(a) ()
>
> IS_UNARY((a)) // 1
> IS_UNARY((a)abc) // 1
> IS_UNARY(+) // 0
> IS_UNARY(xyz) // 0
>
> _______________________________________________
> Unsubscribe & other changes:
> http://lists.boost.org/mailman/listinfo.cgi/boost
>


"pp.cpp", line 7.1: 1506-041 (E) The invocation of macro BOOST_PP_SEQ_ELEM_III contains fewer arguments than required by the macro definition.
"pp.cpp", line 8.1: 1506-041 (E) The invocation of macro BOOST_PP_SEQ_ELEM_III contains fewer arguments than required by the macro definition.
#line 7 "pp.cpp"
1, BOOST_PP_NIL ( ~)(0)
1, BOOST_PP_NIL ( ~abc)(0)
0
0
#line 15
0
0
0
0


"pp.cpp", line 7.1: 1540-0861 (S) Too few arguments are specified for macro "BOOST_PP_SEQ_ELEM_III". Empty arguments are used.
"/home/tk/cvstop/boost/boost/preprocessor/seq/elem.hpp", line 39.13: 1540-0425 (I) "BOOST_PP_SEQ_ELEM_III" is defined on line 39 of "pp.cpp".
"pp.cpp", line 8.1: 1540-0861 (S) Too few arguments are specified for macro "BOOST_PP_SEQ_ELEM_III". Empty arguments are used.
"/home/tk/cvstop/boost/boost/preprocessor/seq/elem.hpp", line 39.13: 1540-0425 (I) "BOOST_PP_SEQ_ELEM_III" is defined on line 39 of "pp.cpp".


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk