Chris Kitching cf50b4f97a Don't special-case source locations for calls in macros
The source location for a call that's inside a macro body will,
by default, point into the macro definition itself. The original
logic was causing macro invocations to be overwritten, as I
explain here:
https://github.com/ROCm-Developer-Tools/HIP/issues/207#issuecomment-337521851

The existing PPCallbacks code is correctly rewriting macro
definitions, so the practical effect of this change is that AST
rewrites on code that's expanded from macros are no-ops.

It might be a performance optimisation to put a short-circiut at
the top of the AST callbacks to abort when faced with code that
was expanded from macros.

It might yet prove wise to do absolutely everything at lex-time...


[ROCm/clr commit: f7e65c5334]
2017-10-26 17:26:37 +01:00
S
Опис
Немає опису
282 MiB
Мови
C++ 67.5%
C 20.6%
Python 6.6%
CMake 3.4%
Shell 0.6%
Інші 1.1%