
Sebastian,
preprocessor can not do parsing of C++ tokens for you, so it can not strip
template paramters. You approach should be reversed:
SOME_MAGIC_DEF_MACRO(myVec, type_seq) should take a boost preprocessor
sequence and genrate a template class instantiation and your pod type.
Macro input would be:
SOME_MAGIC_DEF_MACRO(myVec, ((int)(char)(double)(size_t)(whatever_type)))
This macro expansion should result in:
fusion::vector
Hi there!
The fusion library seems to be the choice for handling tuple-like data in C++. However, for some reasons I would like to be able to transform a fusion vector into a pod object. Something like:
fusion::vector
myVec; SOME_MAGIC_ADAPTER_MACRO(myVec)
The macro or whatever should then turn the vector into
struct myVec_pod { int v1; double v2; float v3; };
or similar. Is this possible?
Greetings,
Sebastian Weber
_______________________________________________ Boost-users mailing list Boost-users@lists.boost.org http://lists.boost.org/mailman/listinfo.cgi/boost-users