diff options
author | Chris Lattner <sabre@nondot.org> | 2009-01-26 00:43:02 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-01-26 00:43:02 +0000 |
commit | de7aeefc5573d669ed476d7bda7a8940d3bcadb7 (patch) | |
tree | b5f4fa05086f338809a94ec330d26860961c1df2 /lib/Rewrite/Rewriter.cpp | |
parent | 51abf6b3bfe03fe9a22d7865da65580e682f9672 (diff) |
Check in the long promised SourceLocation rewrite. This lays the
ground work for implementing #line, and fixes the "out of macro ID's"
problem.
There is nothing particularly tricky about the code, other than the
very performance sensitive SourceManager::getFileID() method.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@62978 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Rewrite/Rewriter.cpp')
-rw-r--r-- | lib/Rewrite/Rewriter.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Rewrite/Rewriter.cpp b/lib/Rewrite/Rewriter.cpp index e92bd7d329..551fa1d491 100644 --- a/lib/Rewrite/Rewriter.cpp +++ b/lib/Rewrite/Rewriter.cpp @@ -151,7 +151,7 @@ std::string Rewriter::getRewritenText(SourceRange Range) const { unsigned Rewriter::getLocationOffsetAndFileID(SourceLocation Loc, FileID &FID) const { assert(Loc.isValid() && "Invalid location"); - std::pair<FileID,unsigned> V = SourceMgr->getDecomposedFileLoc(Loc); + std::pair<FileID,unsigned> V = SourceMgr->getDecomposedLoc(Loc); FID = V.first; return V.second; } |