diff options
author | Chris Lattner <sabre@nondot.org> | 2009-05-28 05:39:39 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-05-28 05:39:39 +0000 |
commit | 3c17b8a4306b84c05454168128bc705b33a79ca3 (patch) | |
tree | 7c1b0100ef22f56e67d48ef051b7d900aead78bf /lib/Frontend/PrintParserCallbacks.cpp | |
parent | 6b73568bc3d44ac6e6d62437cba0e307cf8900d6 (diff) |
fix the "pasting formed 'a]', an invalid preprocessing token"
diagnostic to include the full instantiation location for the
invalid paste. For:
#define foo(a, b) a ## b
#define bar(x) foo(x, ])
bar(a)
bar(zdy)
Instead of:
t.c:3:22: error: pasting formed 'a]', an invalid preprocessing token
#define foo(a, b) a ## b
^
t.c:3:22: error: pasting formed 'zdy]', an invalid preprocessing token
we now produce:
t.c:7:1: error: pasting formed 'a]', an invalid preprocessing token
bar(a)
^
t.c:4:16: note: instantiated from:
#define bar(x) foo(x, ])
^
t.c:3:22: note: instantiated from:
#define foo(a, b) a ## b
^
t.c:8:1: error: pasting formed 'zdy]', an invalid preprocessing token
bar(zdy)
^
t.c:4:16: note: instantiated from:
#define bar(x) foo(x, ])
^
t.c:3:22: note: instantiated from:
#define foo(a, b) a ## b
^
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@72519 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Frontend/PrintParserCallbacks.cpp')
0 files changed, 0 insertions, 0 deletions