[Libreoffice-commits] core.git: 2 commits - compilerplugins/clang .gitignore
Noel Grandin
noel.grandin at collabora.co.uk
Tue Nov 1 11:14:48 UTC 2016
.gitignore | 7 +++++++
compilerplugins/clang/unnecessaryoverride.cxx | 12 ++++--------
2 files changed, 11 insertions(+), 8 deletions(-)
New commits:
commit 2f71f88cf8a0970ad4e2daac30b7a12d6c222d87
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date: Tue Nov 1 13:02:53 2016 +0200
add Codelite files to .gitignore
Change-Id: I464748061b9df4d781ae49f4971f73d92f825bba
diff --git a/.gitignore b/.gitignore
index 4d92213..1e505d6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -153,3 +153,10 @@ DerivedData
# gdb config
/.gdbinit
/.gdb_history
+
+# Codelite IDE specific
+*.project
+/.codelite
+*.workspace
+*.workspace.session
+*.tags
\ No newline at end of file
commit 5e997f4dba1cfcde554ff413a615e101b9c72ee5
Author: Noel Grandin <noel.grandin at collabora.co.uk>
Date: Tue Nov 1 12:58:17 2016 +0200
disable this chunk of loplugin code on clang < 3.8
not worth the spaghetti of making it work across version
Change-Id: I0de923b16fb6d58cbad55adc9878ab39bc0c86ae
diff --git a/compilerplugins/clang/unnecessaryoverride.cxx b/compilerplugins/clang/unnecessaryoverride.cxx
index 96da48c..953abcb 100644
--- a/compilerplugins/clang/unnecessaryoverride.cxx
+++ b/compilerplugins/clang/unnecessaryoverride.cxx
@@ -222,13 +222,12 @@ const CXXMethodDecl* UnnecessaryOverride::findOverriddenOrSimilarMethodInSupercl
return nullptr;
}
+#if CLANG_VERSION < 30800
+ return nullptr;
+#else
std::vector<const CXXMethodDecl*> maSimilarMethods;
-#if CLANG_VERSION >= 30800
auto BaseMatchesCallback = [&](const CXXBaseSpecifier *cxxBaseSpecifier, CXXBasePath& )
-#else
- auto BaseMatchesCallback = [&](const CXXBaseSpecifier *cxxBaseSpecifier, CXXBasePath&, void* )
-#endif
{
if (cxxBaseSpecifier->getAccessSpecifier() != AS_public && cxxBaseSpecifier->getAccessSpecifier() != AS_protected)
return false;
@@ -269,16 +268,13 @@ const CXXMethodDecl* UnnecessaryOverride::findOverriddenOrSimilarMethodInSupercl
};
CXXBasePaths aPaths;
-#if CLANG_VERSION >= 30800
methodDecl->getParent()->lookupInBases(BaseMatchesCallback, aPaths);
-#else
- methodDecl->getParent()->lookupInBases(BaseMatchesCallback, nullptr, aPaths);
-#endif
if (maSimilarMethods.size() == 1) {
return maSimilarMethods[0];
}
return nullptr;
+#endif
}
More information about the Libreoffice-commits
mailing list