summaryrefslogtreecommitdiff
path: root/compilerplugins/clang/unusedvariablemore.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2020-08-03 14:56:33 +0200
committerStephan Bergmann <sbergman@redhat.com>2020-08-03 23:18:58 +0200
commit5c7e838714f5d071c4882115cef9c843fb603287 (patch)
tree8373a8b33fef444b1840c43adb172c30e8417935 /compilerplugins/clang/unusedvariablemore.cxx
parente0018be102edd6e376e0622e0a9384176d2f119c (diff)
Revert "Adapt to changed clang::ASTContext::getParents behavior on Clang 11 trunk"
This reverts commit 09aa5a9be8b9b3c88cf25b85e0eda28c5ef19aa4, now that <https://github.com/llvm/llvm-project/commit/ 551092bc3dfb86f1e11a55f3bee0c8ee1be6fdd6> "Revert AST Matchers default to AsIs mode" reverted the Clang commit that prompted this compilerplugins change. Change-Id: I75c8b4cb2894cd67a791db460f2886a783856c73 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100026 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'compilerplugins/clang/unusedvariablemore.cxx')
-rw-r--r--compilerplugins/clang/unusedvariablemore.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/compilerplugins/clang/unusedvariablemore.cxx b/compilerplugins/clang/unusedvariablemore.cxx
index 484cab088843..b4394b31f8d6 100644
--- a/compilerplugins/clang/unusedvariablemore.cxx
+++ b/compilerplugins/clang/unusedvariablemore.cxx
@@ -204,7 +204,7 @@ bool UnusedVariableMore::checkifUnused(Stmt const* stmt, VarDecl const* varDecl)
if (!parent)
{
// check if we're inside a CXXCtorInitializer
- auto parentsRange = getParents(*stmt);
+ auto parentsRange = compiler.getASTContext().getParents(*stmt);
if (parentsRange.begin() != parentsRange.end())
{
auto parentDecl = parentsRange.begin()->get<Decl>();