Boost logo

Boost :

From: Andy Little (andy_at_[hidden])
Date: 2006-05-05 06:43:51

"David Abrahams" wrote
> "Andy Little" writes:

> > "Pedro Lamarão" wrote
> >
> >> I would like to see some "motivating example", like this one from the
> >> MPL documentation:
> >>
> >>
> >
> > If the above is a motivating example for mpl
> It's not meant to be, really. It's designed to get the reader
> acquainted with the library's fundamental abstractions.
> > then I dont think it is the best one.
> It's true, but not for the reasons you suggest. The problem is that
> in this example there is no code generation, only typechecking, which
> makes it not a very good representative of what metaprogramming can
> do.


> > The interface in this case ( The visible part. e.g for use in
> > function signatures etc) is in the template signature of the
> > class. IMO mpl isnt the best way to implement the dimension of a
> > quantity for this reason.
> If you mean that using mpl::transform on the builtin MPL sequences
> isn't the best approach, I'm inclined to agree. It's a somewhat naive
> approach designed to demonstrate some of the fundamental concepts in
> the library. I wouldn't agree if you were to suggest that MPL can't
> be useful anywhere in implementing such a library.
> > I am sorry to go on about this,
> Well, it is rather a strange outburst to find in the middle of the
> Fusion review thread, where someone just referred to the MPL doc to
> make a point.

I think the point that was being made unintentionally continues a misleading but
prevalent impression regarding that example ...

> Maybe you should bring it up separately if you want to
> talk about this.

The point of my previous post here was to try to correct the impression that the
approach in

is the "one true"/ best/ optimal way to approach the problems of compile time
dimensions. Your answers here are somewhat reassuring me that I wont need to
work as hard now to explain my decision to use another approach, if the issue
comes up in the hopefully imminent pqs review. Thanks for taking the time to
answer and apologies from diverting attention from the Fusion review.

Andy Little

Boost list run by bdawes at, gregod at, cpdaniel at, john at