summaryrefslogtreecommitdiffstats
path: root/clang/tools/libclang/CIndex.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/tools/libclang/CIndex.cpp')
-rw-r--r--clang/tools/libclang/CIndex.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/tools/libclang/CIndex.cpp b/clang/tools/libclang/CIndex.cpp
index 25434164f49..3654a58a5d4 100644
--- a/clang/tools/libclang/CIndex.cpp
+++ b/clang/tools/libclang/CIndex.cpp
@@ -120,7 +120,7 @@ CXSourceRange cxloc::translateSourceRange(const SourceManager &SM,
EndLoc = SM.getExpansionRange(EndLoc).second;
if (R.isTokenRange() && !EndLoc.isInvalid() && EndLoc.isFileID()) {
unsigned Length = Lexer::MeasureTokenLength(EndLoc, SM, LangOpts);
- EndLoc = EndLoc.getFileLocWithOffset(Length);
+ EndLoc = EndLoc.getLocWithOffset(Length);
}
CXSourceRange Result = { { (void *)&SM, (void *)&LangOpts },
@@ -2780,7 +2780,7 @@ CXSourceLocation clang_getLocationForOffset(CXTranslationUnit tu,
1, 1);
if (Start.isInvalid()) return clang_getNullLocation();
- SourceLocation SLoc = Start.getFileLocWithOffset(offset);
+ SourceLocation SLoc = Start.getLocWithOffset(offset);
if (SLoc.isInvalid()) return clang_getNullLocation();
OpenPOWER on IntegriCloud