summaryrefslogtreecommitdiff
path: root/src/tools/clangbackend/source/sourcelocation.cpp
diff options
context:
space:
mode:
authorIvan Donchevskii <ivan.donchevskii@qt.io>2018-01-31 14:44:10 +0100
committerIvan Donchevskii <ivan.donchevskii@qt.io>2018-02-01 08:22:22 +0000
commitb30643c4fa14013aecb71c9968c8c33fb67558d8 (patch)
tree5c530ab8a1444e8fca8b94b77a9d0b78d9f5e07b /src/tools/clangbackend/source/sourcelocation.cpp
parent66d02773e7abe16803ab106f20936a8a24d52730 (diff)
downloadqt-creator-b30643c4fa14013aecb71c9968c8c33fb67558d8.tar.gz
Clang: fix CINDEX_VERSION_MINOR for clang_getFileContents
Change-Id: Id546906fb119be2415500ae13f64c2c0e1e6a81b Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
Diffstat (limited to 'src/tools/clangbackend/source/sourcelocation.cpp')
-rw-r--r--src/tools/clangbackend/source/sourcelocation.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/tools/clangbackend/source/sourcelocation.cpp b/src/tools/clangbackend/source/sourcelocation.cpp
index d015cad4ee..41f68a9ae6 100644
--- a/src/tools/clangbackend/source/sourcelocation.cpp
+++ b/src/tools/clangbackend/source/sourcelocation.cpp
@@ -93,8 +93,8 @@ SourceLocation::SourceLocation(CXTranslationUnit cxTranslationUnit,
return;
filePath_ = ClangString(clang_getFileName(cxFile));
-// CLANG-UPGRADE-CHECK: Remove HAS_GETFILECONTENTS_BACKPORTED check once we require clang >= 6.0
-#if defined(CINDEX_VERSION_HAS_GETFILECONTENTS_BACKPORTED) || CINDEX_VERSION_MINOR >= 44
+// CLANG-UPGRADE-CHECK: Remove HAS_GETFILECONTENTS_BACKPORTED check once we require clang >= 7.0
+#if defined(CINDEX_VERSION_HAS_GETFILECONTENTS_BACKPORTED) || CINDEX_VERSION_MINOR >= 47
if (column_ > 1) {
const uint lineStart = offset_ + 1 - column_;
const char *contents = clang_getFileContents(cxTranslationUnit, cxFile, nullptr);