Boost logo

Boost :

From: Hartmut Kaiser (hartmut.kaiser_at_[hidden])
Date: 2005-05-05 11:06:39


 
Andrei Alexandrescu wrote:

> 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.

FYI, Wave has a special #pragma usable for bridging this gap:

    #pragma wave system(any OS command)

which spawns of the given command and intercepts the produced stdout stream,
inserting it instead of the pragma itself :-P. In C99 mode you even may use
it from the operator _Pragma and force a full macro expansion of the
inserted results:

#define EVAL(x) x
EVAL(_Pragma("wave system(any OS command)"))

Regards Hartmut


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