Boost logo

Boost :

From: Vesa Karvonen (vesa_karvonen_at_[hidden])
Date: 2003-04-14 07:17:23


Paul Mensonides:
[...]
>I need input regarding the paper itself and anything that should be
>added or subtracted from the paper.
[...]

It looks quite reasonable and very conservative to me.

It is difficult to imagine a really good reason not to adopt the C99
preprocessor extensions into C++.

Well-defined token-pasting is also reasonable.

The way I see it, the module system is the only real extension - and the
most difficult to justify. The way I understand it, the module system
doesn't make the macro system much safer for macro users. It probably makes
macros safer for users of ordinary libraries (who don't want to care about
the macros). (The C preprocessor is nowhere near as safe as the hygienic
(and mostly hygienic) macros of Scheme, for instance.)

I think that it would not necessarily be wise to use lowercase names for
macros even with the module system. The problem is that within a module, you
could still get all sorts of nasty surprises if you forget that you have
imported a particular macro (a few hundred lines above). (Contrast this with
Scheme hygienic macros, where ordinary bindings can shadow syntactic
bindings and vice versa. In addition, hygienic macros in Scheme are also
referentially transparent - not unlike templates in C++.)

Also, the syntax for referring to macros, e.g.

  BOOST::QUALIFIED

seems quite ambiquous to me. It looks like three separate tokens. Has
someone implemented a module system that uses this syntax?

-Vesa

_________________________________________________________________
Add photos to your messages with MSN 8. Get 2 months FREE*.
http://join.msn.com/?page=features/featuredemail


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