Boost logo

Boost Users :

From: Arkadiy Vertleyb (vertleyb_at_[hidden])
Date: 2006-10-17 13:32:58


"Terry G" <tjgolubi_at_[hidden]> wrote

> I've just finished reading C++ Template Metaprogramming again.
> I just don't get it.

Should probably not be your first book on template metaprogramming. Really,
it's just like trying to learn STL without any idea what a template is.

> Why would someone use a type container?

For example, one could implement a generic tuple class (although I don't
think boost::tuple uses this approach, but probably fusion does?). Also see
below...

> I'd really like a reference to an MPL primer or some case studies.

IMO, you should really start with template metaprogramming itself, and then
move to MPL. Try Alexandrescu's "Modern C++ design" -- it also contains a
lot of examples why you would want to use a typelist. Once you have a basic
understanding of template metaprogramming, get back to the MPL book -- it's
worth it.

Regards,
Arkadiy


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net