summaryrefslogtreecommitdiff
path: root/tools/libclang/CXSourceLocation.cpp
diff options
context:
space:
mode:
authorAaron Ballman <aaron@aaronballman.com>2017-10-21 21:52:48 +0000
committerAaron Ballman <aaron@aaronballman.com>2017-10-21 21:52:48 +0000
commitb99743553a954ef2e92d143890fe987500088ff8 (patch)
tree8ddf5a7587df37cd66ef977ce4b3124e25007a79 /tools/libclang/CXSourceLocation.cpp
parentd02b8c6579d1e6a51f6c5c289943ecba97e1a1f9 (diff)
downloadclang-b99743553a954ef2e92d143890fe987500088ff8.tar.gz
Reverting r316278 due to failing build bots.
http://lab.llvm.org:8011/builders/clang-ppc64be-linux/builds/11896 http://lab.llvm.org:8011/builders/clang-s390x-linux/builds/12380 git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@316279 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'tools/libclang/CXSourceLocation.cpp')
-rw-r--r--tools/libclang/CXSourceLocation.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/tools/libclang/CXSourceLocation.cpp b/tools/libclang/CXSourceLocation.cpp
index b1637e01ab..2e0ea4e440 100644
--- a/tools/libclang/CXSourceLocation.cpp
+++ b/tools/libclang/CXSourceLocation.cpp
@@ -318,7 +318,8 @@ void clang_getSpellingLocation(CXSourceLocation location,
const SourceManager &SM =
*static_cast<const SourceManager*>(location.ptr_data[0]);
- SourceLocation SpellLoc = SM.getSpellingLoc(Loc);
+ // FIXME: This should call SourceManager::getSpellingLoc().
+ SourceLocation SpellLoc = SM.getFileLoc(Loc);
std::pair<FileID, unsigned> LocInfo = SM.getDecomposedLoc(SpellLoc);
FileID FID = LocInfo.first;
unsigned FileOffset = LocInfo.second;