
-----Original Message----- From: boost-bounces@lists.boost.org [mailto:boost-bounces@lists.boost.org] On Behalf Of Rene Rivera
[snip]
a look at the preprocessor library but I couldnt come up with a solution. Is there an alternative to the macros for registering types? (A sample program exhibiting what I am trying is attached.) [snip] // Doesn't work (wrong number of macro arguments ): // BOOST_CLASS_EXPORT( DerivedStatus< Algo< int, double > > );
Did you try using BOOST_PP_COMMA ?? For example:
BOOST_CLASS_EXPORT( DerivedStatus< Algo< int BOOST_PP_COMMA double > > );
Should be with nullary parentheses: BOOST_CLASS_EXPORT( DerivedStatus< Algo<int BOOST_PP_COMMA() double > > ); Incidently, do we have a function argument mapping for the common case of this type of thing? E.g. template<class> struct pack; template<class T> struct pack<void (T)> { typedef T type; }; BOOST_CLASS_EXPORT( pack<void (DerivedStatus< Algo<int, double > >)>::type ); Or similar? The COMMA() trick will only work through one level of macro expansion. Regards, Paul Mensonides