This is the mail archive of the gcc-patches@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: [PATCH preprocessor, diagnostics] PR preprocessor/53229 - Fix diagnostics location when pasting tokens


>>>>> "Dodji" == Dodji Seketeli <dodji@redhat.com> writes:

Dodji> To properly fix this, I think libcpp should keep the token of the
Dodji> pasting operator '##', instead of representing it with flag on the LHS
Dodji> operand's token.  That way, it could use its location.

Originally I had thought that a pasted token should have a special
virtual location, pointing to the locations of its source tokens.
This would let later code "undo" the paste, if need be.

I don't know any more if this idea makes sense or not.

Tom


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