summaryrefslogtreecommitdiffstats
path: root/clang/lib/Lex
diff options
context:
space:
mode:
authorChandler Carruth <chandlerc@gmail.com>2011-07-08 01:04:21 +0000
committerChandler Carruth <chandlerc@gmail.com>2011-07-08 01:04:21 +0000
commit2536c072f76f355a4ddc3c8ddced9098f5f9d03f (patch)
tree61cadbc79bd3317d28b0481dc6104c262171b6a8 /clang/lib/Lex
parentf4e9a4c67619747d50cce9fa1f69b568459ab0b1 (diff)
downloadbcm5719-llvm-2536c072f76f355a4ddc3c8ddced9098f5f9d03f.tar.gz
bcm5719-llvm-2536c072f76f355a4ddc3c8ddced9098f5f9d03f.zip
Switch the token-paste source locations inside of function style macro
argument expansion to use the macro argument source locations as well. Add a few tests to exercise this. There is still a bit more work needed here though. llvm-svn: 134674
Diffstat (limited to 'clang/lib/Lex')
-rw-r--r--clang/lib/Lex/TokenLexer.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/Lex/TokenLexer.cpp b/clang/lib/Lex/TokenLexer.cpp
index fac6b7dc3ea..8aa2c79ac30 100644
--- a/clang/lib/Lex/TokenLexer.cpp
+++ b/clang/lib/Lex/TokenLexer.cpp
@@ -289,9 +289,9 @@ void TokenLexer::ExpandFunctionArguments() {
for (unsigned i = ResultToks.size() - NumToks, e = ResultToks.size();
i != e; ++i) {
Token &Tok = ResultToks[i];
- Tok.setLocation(SM.createInstantiationLoc(Tok.getLocation(),
- curInst, curInst,
- Tok.getLength()));
+ Tok.setLocation(SM.createMacroArgInstantiationLoc(Tok.getLocation(),
+ curInst,
+ Tok.getLength()));
}
}
OpenPOWER on IntegriCloud