This is the mail archive of the gcc-help@gcc.gnu.org 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: missing terminating ' character


Thanks for your clarifications Brian. I have "fixed" by expectations :-)

Cheers
Hari

Brian Dessent wrote:
Hariharan wrote:

I am not exactly sure if this is buggy behaviour, but it obviously isnt
what i would have expected.

Please clarify if this is a bug.

It's a bug in your expectations. "#if 0" is not the same as a glorified comment marker. The text it contains must still consist of valid preprocessor tokens, because it must still remain parsable by the preprocessor. Consider for example that "#endif" could occur inside a backslash-newline-continued string and in that case it is a string literal and not treated as an #endif by the preprocessor. So, the preprocessor has to care about balanced quotes, even in text that it is discarding.

Brian


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