From: Jeff Garland (jeff_at_[hidden])
Date: 2002-04-10 20:51:25
David B. Held
> So you're saying that only library writers will ever use MPL or Loki
Yes, I'm saying that other than creation of a typelist the internals of typelist functions aren't
relevant to most users. I base this on the current examples of typelist usage that have been
enumerated in MC++D. In all these cases the usage of the typelist of the library user is basically
'construct' and pass to the library to generate something. The example Dave and Aleksey give in
their paper of a finite state machine is similar.
> I admit that I have never felt a compelling urge to use them
> in my own code, but I think that has more to do with lack of experience
> than lack of need. And what I see over and over again is that despite
> the presence of great libraries, people do, in fact, invent the wheel
> many times, and often because the generic wheel is unsuitable for some
> corner case that is not easy to address. In those cases, "end users" become
> "library writers" in some sense. I would imagine those people would
> like to have nice tools without getting a Ph.D in advanced C++ design. ;)
> For instance, people have already mentioned creating an uncountable
> number of smart pointer types because boost::smart_ptr or
> Loki::SmartPtr just didn't solve some particular problem they had,
> or at least they didn't see how it could.
Smart pointer doesn't use typelist.
> If typelist manipulation is something only library writers will ever need to
> do, I will be happy to leave the debate to the library writers. However, it
> seems to me that as generic programming becomes more popular, using typelists
> in non-library contexts will only become more common, not less (unfortunately,
> I'm not clever enough to come up with some concrete examples...on the other
> hand, people probably couldn't imagine what could be done with OOP when it first came
> out, and probably a few people said that building object hierarchies is the
> business of library writers, and end users only had to understand the resulting
I think typelists are really cool and useful, but I believe their utility is fairly limited. The
number of applications will surely increase, but I doubt you will see typelists littering 'average'
(whatever that is) C++ code.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk