summaryrefslogtreecommitdiff
path: root/compilerplugins/clang/noexceptmove.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <stephan.bergmann@allotropia.de>2024-05-05 17:09:24 +0200
committerStephan Bergmann <stephan.bergmann@allotropia.de>2024-05-05 22:30:56 +0200
commit7a895ec4205659038aa95941b65715fed1a3e7be (patch)
treecfe3e5168dbb0fd2cce827e7459e38e099be23ff /compilerplugins/clang/noexceptmove.cxx
parent42794558768d4beb0321271457f675976970241f (diff)
Avoid loplugin:noexceptmove failure with recent Clang 19 trunk
> CallExpr 0x7fae572c85e0 '<dependent type>' > `-UnresolvedMemberExpr 0x7fae572c8580 '<bound member function type>' lvalue > `-DeclRefExpr 0x7fae572c8560 'WeakReference<reference_type>' lvalue ParmVar 0x7fae572c76d0 'rWeakRef' 'WeakReference<reference_type> &&' > In file included from tools/source/ref/ref.cxx:21: > include/tools/weakbase.hxx:52:5: error: what's up doc? [loplugin:noexceptmove] > 52 | rWeakRef.reset(); > | ^~~~~~~~~~~~~~~~ Change-Id: I5693fda3c4e5afb02e6229bcb8ea952a62f0e363 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/167157 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <stephan.bergmann@allotropia.de>
Diffstat (limited to 'compilerplugins/clang/noexceptmove.cxx')
-rw-r--r--compilerplugins/clang/noexceptmove.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/compilerplugins/clang/noexceptmove.cxx b/compilerplugins/clang/noexceptmove.cxx
index 04ec58044ce4..9be55e870e61 100644
--- a/compilerplugins/clang/noexceptmove.cxx
+++ b/compilerplugins/clang/noexceptmove.cxx
@@ -286,7 +286,8 @@ compat::optional<bool> NoExceptMove::IsCallThrows(const CallExpr* callExpr)
}
auto calleeExpr = callExpr->getCallee();
- if (isa<CXXDependentScopeMemberExpr>(calleeExpr) || isa<UnresolvedLookupExpr>(calleeExpr))
+ if (isa<CXXDependentScopeMemberExpr>(calleeExpr) || isa<UnresolvedLookupExpr>(calleeExpr)
+ || isa<UnresolvedMemberExpr>(calleeExpr))
{
m_CannotFix.back() = true;
return true;