aboutsummaryrefslogtreecommitdiff
path: root/Driver/RewriteMacros.cpp
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2009-01-16 07:36:28 +0000
committerChris Lattner <sabre@nondot.org>2009-01-16 07:36:28 +0000
commitf7cf85b330bedd2877e1371fb0a83e99751ae162 (patch)
tree6674dd8f06d3c395ab61ad9770934c49572e200c /Driver/RewriteMacros.cpp
parent88054dee0402e4d3c1f64e6b697acc47195c0d72 (diff)
more SourceLocation lexicon change: instead of referring to the
"logical" location, refer to the "instantiation" location. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62316 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'Driver/RewriteMacros.cpp')
-rw-r--r--Driver/RewriteMacros.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Driver/RewriteMacros.cpp b/Driver/RewriteMacros.cpp
index d10bf55853..fb423c6413 100644
--- a/Driver/RewriteMacros.cpp
+++ b/Driver/RewriteMacros.cpp
@@ -113,7 +113,7 @@ void clang::RewriteMacrosInInput(Preprocessor &PP,const std::string &InFileName,
// that aren't in the preprocessed view, we have macros that expand to no
// tokens, or macro arguments etc.
while (RawTok.isNot(tok::eof) || PPTok.isNot(tok::eof)) {
- SourceLocation PPLoc = SM.getLogicalLoc(PPTok.getLocation());
+ SourceLocation PPLoc = SM.getInstantiationLoc(PPTok.getLocation());
// If PPTok is from a different source file, ignore it.
if (!SM.isFromMainFile(PPLoc)) {
@@ -198,7 +198,7 @@ void clang::RewriteMacrosInInput(Preprocessor &PP,const std::string &InFileName,
while (PPOffs < RawOffs) {
Expansion += ' ' + PP.getSpelling(PPTok);
PP.Lex(PPTok);
- PPLoc = SM.getLogicalLoc(PPTok.getLocation());
+ PPLoc = SM.getInstantiationLoc(PPTok.getLocation());
PPOffs = SM.getFullFilePos(PPLoc);
}
Expansion += ' ';