From: Andrei Alexandrescu (See Website For Email) (SeeWebsiteForEmail_at_[hidden])
Date: 2005-05-04 15:45:30
Arkadiy Vertleyb wrote:
> "Thorsten Ottosen" <nesotto_at_[hidden]> wrote
>>Nevertheless, the preprocessor is a good way to generate some tedious
>>just look inside boost.assign.
> And sometimes, I think, it's _the only_ way. If you are interested, please
> take a look at typeof_internals.htm.zip in the boost sandbox file vault.
The only way as long as you commit to not look outside C++. There are
plenty of text manipulation tools outside C++ that offer what could be
done with the C++ preprocessor with programming paradigms that I
consider unworthy of learning. Those tools (sed, awk, perl) are widely
available, and in my humble opinion any programmer worth her salt should
have at least a cursory understanding of them.
Those tools also offer more power than the C++ preprocessor, within the
confines of a much more pleasant programming paradigm. (Well don't start
an anti-sed war now though. :o)) A line must be drawn somewhere (after
all we do use a makefile and not a little C++ program for builds don't
we), and I would draw it someplace else than others. For example, if
someone doesn't know awk, I'd suggest them to invest time in learning
that instead of the boost preprocessor library.
So when will the vote result on FOREACH come forth?
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk