This is the mail archive of the mailing list for the GCC project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: cpp macro expansion for #pragmas

Paul Rubin <> writes:

> This is revived from several months back.  It adds cpp macro expansion
> capability for #pragma directives, under control of a gcc command line
> option (-expand-pragmas).  It's against version 117267 of the svn
> tree, which is now a day or so old, except the testsuite/ChangeLog
> diff is against a newer revision (but changelogs always get patch
> conflicts anyway).  I'd like to submit it for GCC 4.3.  I've run the
> full gcc test suite and while there are a number of unexpected
> failures and successes, they're in non-cpp-related areas and I get the
> same failures when running the tests using the unpatched cpp (2
> unexpected failures in C, one unexpected success in C++, and 16
> unexpected failures in Fortran, IIRC.  I think Fortran does not use
> the cpp at all).  Please let me know of any probs.

This is an interesting idea, but it seems to me that pragma expansion
should itself be under the control of a pragma.  Otherwise you have
program which will have surprisingly different behaviour depending
upon the command line options used.  Is that doable?

Not that this should block the acceptance of this patch, which I can't
approve anyhow.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]