Re: Boost Workshop at OOPSLA 2004
"Paul Mensonides" <leavings@comca st.net> writes:
[color=blue]
> "David Abrahams" <dave@boost-consulting.com> wrote in message
> news:u1xiciifa. fsf@boost-consulting.com. ..
>[color=green]
> > Yes, but as I mentioned none of that is required in std C++.
> > http://sourceforge.net/projects/chaos-pp/ doesn't use any
> > program-generated macros.[/color]
>
> It does use some, but not for algorithmic constructs. E.g. the closest
> equivalent (i.e. as feature-lacking as possible) to BOOST_PP_REPEAT under Chaos
> is:
>
> #include <chaos/preprocessor/arithmetic/dec.h>
> #include <chaos/preprocessor/control/when.h>
> #include <chaos/preprocessor/recursion/basic.h>
> #include <chaos/preprocessor/recursion/expr.h>
>
> #define REPEAT(count, macro, data) \
> REPEAT_S(CHAOS_ PP_STATE(), count, macro, data) \
> /**/
> #define REPEAT_S(s, count, macro, data) \
> REPEAT_I( \
> CHAOS_PP_OBSTRU CT(), CHAOS_PP_NEXT(s ), \
> count, macro, data \
> ) \
> /**/
> #define REPEAT_INDIRECT () REPEAT_I
> #define REPEAT_I(_, s, count, macro, data) \
> CHAOS_PP_WHEN _(count)( \
> CHAOS_PP_EXPR_S _(s)(REPEAT_IND IRECT _()( \
> CHAOS_PP_OBSTRU CT _(), CHAOS_PP_NEXT(s ), \
> CHAOS_PP_DEC(co unt), macro, data \
> )) \
> macro _(s, CHAOS_PP_DEC(co unt), data) \
> ) \
> /**/[/color]
Confused. I don't see anything here that looks like a
program-generated macro.
--
Dave Abrahams
Boost Consulting
[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.m oderated. First time posters: Do this! ]
"Paul Mensonides" <leavings@comca st.net> writes:
[color=blue]
> "David Abrahams" <dave@boost-consulting.com> wrote in message
> news:u1xiciifa. fsf@boost-consulting.com. ..
>[color=green]
> > Yes, but as I mentioned none of that is required in std C++.
> > http://sourceforge.net/projects/chaos-pp/ doesn't use any
> > program-generated macros.[/color]
>
> It does use some, but not for algorithmic constructs. E.g. the closest
> equivalent (i.e. as feature-lacking as possible) to BOOST_PP_REPEAT under Chaos
> is:
>
> #include <chaos/preprocessor/arithmetic/dec.h>
> #include <chaos/preprocessor/control/when.h>
> #include <chaos/preprocessor/recursion/basic.h>
> #include <chaos/preprocessor/recursion/expr.h>
>
> #define REPEAT(count, macro, data) \
> REPEAT_S(CHAOS_ PP_STATE(), count, macro, data) \
> /**/
> #define REPEAT_S(s, count, macro, data) \
> REPEAT_I( \
> CHAOS_PP_OBSTRU CT(), CHAOS_PP_NEXT(s ), \
> count, macro, data \
> ) \
> /**/
> #define REPEAT_INDIRECT () REPEAT_I
> #define REPEAT_I(_, s, count, macro, data) \
> CHAOS_PP_WHEN _(count)( \
> CHAOS_PP_EXPR_S _(s)(REPEAT_IND IRECT _()( \
> CHAOS_PP_OBSTRU CT _(), CHAOS_PP_NEXT(s ), \
> CHAOS_PP_DEC(co unt), macro, data \
> )) \
> macro _(s, CHAOS_PP_DEC(co unt), data) \
> ) \
> /**/[/color]
Confused. I don't see anything here that looks like a
program-generated macro.
--
Dave Abrahams
Boost Consulting
[ See http://www.gotw.ca/resources/clcm.htm for info about ]
[ comp.lang.c++.m oderated. First time posters: Do this! ]
Comment