mirror of
https://github.com/boostorg/preprocessor.git
synced 2025-07-15 13:36:33 +02:00
Minor optimizations
[SVN r12462]
This commit is contained in:
@ -34,6 +34,6 @@ NOTE: The implementation uses BOOST_PP_REPEAT().
|
||||
#define BOOST_PP_ENUM(N,F,P) BOOST_PP_REPEAT(N,BOOST_PP_ENUM_F,(F,P))
|
||||
|
||||
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
||||
#define BOOST_PP_ENUM_F(I,FP) BOOST_PP_COMMA_IF(I) BOOST_PP_TUPLE_ELEM(2,0,FP)(I,BOOST_PP_TUPLE_ELEM(2,1,FP))
|
||||
#define BOOST_PP_ENUM_F(I,FP) BOOST_PP_COMMA_IF(I) BOOST_PP_TUPLE2_ELEM0 FP(I,BOOST_PP_TUPLE2_ELEM1 FP)
|
||||
#endif
|
||||
#endif
|
||||
|
@ -33,7 +33,7 @@ NOTE: The implementation uses BOOST_PP_REPEAT().
|
||||
#define BOOST_PP_ENUM_PARAMS_WITH_A_DEFAULT(N,P,D) BOOST_PP_ENUM(N,BOOST_PP_ENUM_PARAMS_WITH_A_DEFAULT_F,(P,D))
|
||||
|
||||
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
||||
#define BOOST_PP_ENUM_PARAMS_WITH_A_DEFAULT_F(I,PD) BOOST_PP_CAT(BOOST_PP_TUPLE_ELEM(2,0,PD),I)=BOOST_PP_TUPLE_ELEM(2,1,PD)
|
||||
#define BOOST_PP_ENUM_PARAMS_WITH_A_DEFAULT_F(I,PD) BOOST_PP_CAT(BOOST_PP_TUPLE2_ELEM0 PD,I)=BOOST_PP_TUPLE2_ELEM1 PD
|
||||
#endif
|
||||
|
||||
//! Obsolete. Use BOOST_PP_ENUM_PARAMS_WITH_A_DEFAULT().
|
||||
|
@ -33,7 +33,7 @@ NOTE: The implementation uses BOOST_PP_REPEAT().
|
||||
#define BOOST_PP_ENUM_PARAMS_WITH_DEFAULTS(N,P,D) BOOST_PP_ENUM(N,BOOST_PP_ENUM_PARAMS_WITH_DEFAULTS_F,(P,D))
|
||||
|
||||
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
||||
#define BOOST_PP_ENUM_PARAMS_WITH_DEFAULTS_F(I,PD) BOOST_PP_CAT(BOOST_PP_TUPLE_ELEM(2,0,PD),I)=BOOST_PP_CAT(BOOST_PP_TUPLE_ELEM(2,1,PD),I)
|
||||
#define BOOST_PP_ENUM_PARAMS_WITH_DEFAULTS_F(I,PD) BOOST_PP_CAT(BOOST_PP_TUPLE2_ELEM0 PD,I)=BOOST_PP_CAT(BOOST_PP_TUPLE2_ELEM1 PD,I)
|
||||
#endif
|
||||
|
||||
//! Obsolete. Use BOOST_PP_ENUM_PARAMS_WITH_DEFAULTS().
|
||||
|
@ -34,6 +34,6 @@ NOTE: The implementation uses BOOST_PP_REPEAT().
|
||||
#define BOOST_PP_ENUM_SHIFTED(N,F,P) BOOST_PP_ENUM(BOOST_PP_DEC(N),BOOST_PP_ENUM_SHIFTED_F,(F,P))
|
||||
|
||||
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
||||
#define BOOST_PP_ENUM_SHIFTED_F(I,FP) BOOST_PP_TUPLE_ELEM(2,0,FP)(BOOST_PP_INC(I),BOOST_PP_TUPLE_ELEM(2,1,FP))
|
||||
#define BOOST_PP_ENUM_SHIFTED_F(I,FP) BOOST_PP_TUPLE2_ELEM0 FP(BOOST_PP_INC(I),BOOST_PP_TUPLE2_ELEM1 FP)
|
||||
#endif
|
||||
#endif
|
||||
|
@ -25,11 +25,11 @@
|
||||
BOOST_PP_IF() enables convenient generation of lists using
|
||||
BOOST_PP_REPEAT().
|
||||
*/
|
||||
#define BOOST_PP_IF(C,T,E) BOOST_PP_IF_BOOL(BOOST_PP_BOOL(C),T,E)
|
||||
#define BOOST_PP_IF(C,T,E) BOOST_PP_IF_BOOL(BOOST_PP_BOOL(C))(E,T)
|
||||
|
||||
#ifndef DOXYGEN_SHOULD_SKIP_THIS
|
||||
#define BOOST_PP_IF_BOOL(C,T,E) BOOST_PP_IF_BOOL_DELAY(C,T,E)
|
||||
#define BOOST_PP_IF_BOOL_DELAY(C,T,E) BOOST_PP_TUPLE2_ELEM##C(E,T)
|
||||
#define BOOST_PP_IF_BOOL(C) BOOST_PP_IF_BOOL_DELAY(C)
|
||||
#define BOOST_PP_IF_BOOL_DELAY(C) BOOST_PP_TUPLE2_ELEM##C
|
||||
#endif
|
||||
|
||||
//! Obsolete. Use BOOST_PP_IF().
|
||||
|
Reference in New Issue
Block a user