This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: cpplib: simplify callbacks, reduce exposed interface
>>>>> "Zack" == Zack Weinberg <zackw@Stanford.EDU> writes:
> On Wed, Nov 29, 2000 at 06:03:38PM +0000, Neil Booth wrote:
>>
>> What do you want to do there? Should we not allow -include with
>> -fpreprocessed? (Sounds like a good idea to me). Regardless, it will
>> cause problems because the output of a file preprocessed with -include
>> will have the first -included file as the line marker at the top.
> Just about everything should be shut off by -fpreprocessed: -include,
> -imacros, -D, -I, ...
Yup.
>> Another thing - how about raising a warning or maybe even an error in
>> cpp if we meet a # line without the -fpreprocessed flag?
> I'd support this, and also removing the ability to specify trailing
> flags on #line. As you say, it can probably cause segfaults and the
> like. It used to be useful to write #line "foobar" 3, but now we have
> #pragma GCC system_header for that.
There are some oddball semi-preprocessed testcases in the g++
testsuite, such as g++.jason/2371.C, which would break with this
change. But that's probably OK.
Jason