diff options
| author | Chris Lattner <sabre@nondot.org> | 2007-07-15 06:35:27 +0000 |
|---|---|---|
| committer | Chris Lattner <sabre@nondot.org> | 2007-07-15 06:35:27 +0000 |
| commit | 3fc74e2468ca6952882affbf6f0c3ded3047ae5d (patch) | |
| tree | 4574f1198766bb05f097b8271a090ee9e40eec3a /clang/Lex/MacroExpander.cpp | |
| parent | 81569d2044c64a960b86080401695745b3d3ee68 (diff) | |
| download | bcm5719-llvm-3fc74e2468ca6952882affbf6f0c3ded3047ae5d.tar.gz bcm5719-llvm-3fc74e2468ca6952882affbf6f0c3ded3047ae5d.zip | |
Change SourceManager::getInstantiationLoc to take virtual locations, doing its
virtual->physical mapping explicitly.
llvm-svn: 39867
Diffstat (limited to 'clang/Lex/MacroExpander.cpp')
| -rw-r--r-- | clang/Lex/MacroExpander.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/Lex/MacroExpander.cpp b/clang/Lex/MacroExpander.cpp index 7a46b142972..c98949ec1d3 100644 --- a/clang/Lex/MacroExpander.cpp +++ b/clang/Lex/MacroExpander.cpp @@ -499,8 +499,8 @@ void MacroExpander::Lex(LexerToken &Tok) { // The token could have come from a prior macro expansion. In that case, // ignore the macro expand part to get to the physloc. This happens for // stuff like: #define A(X) X A(A(X)) A(1) - SourceLocation PhysLoc = SrcMgr.getPhysicalLoc(Tok.getLocation()); - Tok.setLocation(SrcMgr.getInstantiationLoc(PhysLoc, InstantiateLoc)); + Tok.setLocation(SrcMgr.getInstantiationLoc(Tok.getLocation(), + InstantiateLoc)); } // If this is the first token, set the lexical properties of the token to |

