From: Robert Ramey (ramey_at_[hidden])
Date: 2004-08-11 11:14:47
David Abrahams wrote:
"Robert Ramey" <ramey_at_[hidden]> writes:
>> Now that I do, I'm strongly convinced that
>> it's a really bad idea.
>Give it a chance to sink in.
Looks like I don't have much choice.
> It's a good idea even if you ignore
> export because it reduces the chance that a template's meaning will
> change based on definitions that follow it, allows syntax checking
> before instantiation, and adds rigor.
That's the problem with it in my view. Before, I could keep things in my
head by extending the "macro" concept to include types. Now I can't. Now
the meaning of something depends upon the order it is included in the
program - an incredibly subtle side-effect. Worse, the meaning of a
template now can vary quite a bit depending upon the argument used to
instantiate it. The whole thing reminds me of trying to write a memo with
Microsoft word. It constantly "helps you out" without telling you so you
can't really see what's going on without keeping the whole global
environment in your head. So it diminishes transparency, verifiability, and
opportunity to enforce rigor in coding requires increased dependence on
testing to gain confidence on program correctness. Sorry, I know we're
going off topic, but I couldn't let the above pass without comment.
>> CW < 8
>> I believe that these versions will pass 100 %
>I wouldn't count on it. CW 7.x couldn't handle the "sizeof() trick",
>so *lots* of basic TMP things (like is_convertible) fail there. Of
>course, maybe you're sure that none of these things are used...?
Good thing you didn't tell me that before - its now passing 100% It feels
like I've used everything in mpl (of course I didn't - it just feels like I
did). I use is_convertible in many places as well as just about all the
On the other hand, maybe its just that I don't have enough tests to make it
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk