summaryrefslogtreecommitdiff
path: root/compilerplugins/clang/unusedmethods.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2017-12-15 14:20:38 +0100
committerStephan Bergmann <sbergman@redhat.com>2017-12-19 22:08:38 +0100
commit9663341f9249c739219ffe6cccf3762aa8dd78f3 (patch)
tree2b22177d01916abca8314b0834185892a8f77030 /compilerplugins/clang/unusedmethods.cxx
parent00bc5a097313fbd003675267be961ad3a152ba42 (diff)
Bump --enable-compiler-plugins to Clang 3.8.0
<https://lists.freedesktop.org/archives/libreoffice/2017-December/079107.html> "Clang baseline bump" Change-Id: I18fca8794ea34118fc6308458064d0c28cf5caf7 Reviewed-on: https://gerrit.libreoffice.org/46557 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'compilerplugins/clang/unusedmethods.cxx')
-rw-r--r--compilerplugins/clang/unusedmethods.cxx7
1 files changed, 2 insertions, 5 deletions
diff --git a/compilerplugins/clang/unusedmethods.cxx b/compilerplugins/clang/unusedmethods.cxx
index 9122e3565d54..6ea3da69716b 100644
--- a/compilerplugins/clang/unusedmethods.cxx
+++ b/compilerplugins/clang/unusedmethods.cxx
@@ -136,11 +136,8 @@ MyFuncInfo UnusedMethods::niceName(const FunctionDecl* functionDecl)
functionDecl = functionDecl->getInstantiatedFromMemberFunction();
else if (functionDecl->getClassScopeSpecializationPattern())
functionDecl = functionDecl->getClassScopeSpecializationPattern();
-// workaround clang-3.5 issue
-#if CLANG_VERSION >= 30600
else if (functionDecl->getTemplateInstantiationPattern())
functionDecl = functionDecl->getTemplateInstantiationPattern();
-#endif
MyFuncInfo aInfo;
switch (functionDecl->getAccess())
@@ -151,7 +148,7 @@ MyFuncInfo UnusedMethods::niceName(const FunctionDecl* functionDecl)
default: aInfo.access = "unknown"; break;
}
if (!isa<CXXConstructorDecl>(functionDecl)) {
- aInfo.returnType = compat::getReturnType(*functionDecl).getCanonicalType().getAsString();
+ aInfo.returnType = functionDecl->getReturnType().getCanonicalType().getAsString();
} else {
aInfo.returnType = "";
}
@@ -262,7 +259,7 @@ gotfunc:
}
// Now do the checks necessary for the "unused return value" analysis
- if (compat::getReturnType(*calleeFunctionDecl)->isVoidType()) {
+ if (calleeFunctionDecl->getReturnType()->isVoidType()) {
return true;
}
if (!parent) {