Boost logo

Boost :

From: Joel FALCOU (joel.falcou_at_[hidden])
Date: 2008-06-07 04:53:48


> the meta_class specializations for the templates like pair, vector, tuple, etc.
> are currently hand-coded, and using some common boilerplate to handle
> the template param names, but I'm working on some registering macros
> similar to Joel's.
> see for example:
> http://svn.boost.org/svn/boost/sandbox/mirror/boost/mirror/meta_classes/std_pair.hpp

Seems mirror has a far broader usage than my humnle identify<> !
I like the possibility of reflecting any parts of a type adn I also
understand the gap between this task and mine.

My macro in fact really simple, I "cheat" by using MPL_AUX_LAMBDA_ARITY
to detect the number of tempalte parameters and generate the proper
specialisation. When it fails, I use a small preprocessor macro using
sequence to generate the proper display.

Other difference is my use of std::string as a return type. Seems you
have a complex system to compute string length and use char*. Not sure
which one is the best but I'm willing to hear the rationale behind this
choice.

-- 
Joel FALCOU
Research Engineer @ Institut d'Electronique Fondamentale
Université PARIS SUD XI
France

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