summaryrefslogtreecommitdiffstats
path: root/compilerplugins
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2022-03-28 08:28:51 +0200
committerStephan Bergmann <sbergman@redhat.com>2022-03-28 10:23:20 +0200
commit0792b859147d752bf298eb146ec3b2638cff8bf0 (patch)
tree0f7166c8135c9ed390af28355c2c9972846e9611 /compilerplugins
parentsw clearing breaks: add layout support for the left and right cases (diff)
downloadcore-0792b859147d752bf298eb146ec3b2638cff8bf0.tar.gz
core-0792b859147d752bf298eb146ec3b2638cff8bf0.zip
Adapt loplugin:singlevalfields to AtomicExpr
> AtomicExpr 0xcb01120 'std::__detail::__platform_wait_t':'int' > |-ImplicitCastExpr 0xcb01108 'std::__detail::__platform_wait_t *' <LValueToRValue> > | `-MemberExpr 0xcb01048 'std::__detail::__platform_wait_t *' lvalue ->_M_addr 0xcafd9c8 > | `-CXXThisExpr 0xcb01038 '__waiter_base<_Tp> *' implicit this > |-IntegerLiteral 0xcb01098 'int' 5 > `-IntegerLiteral 0xcb01078 'int' 1 > AtomicExpr 0xd1e2d08 'std::__detail::__platform_wait_t':'int' > |-ImplicitCastExpr 0xd1e2cf0 'std::__detail::__platform_wait_t *' <LValueToRValue> > | `-MemberExpr 0xd1e2cc0 'std::__detail::__platform_wait_t *' lvalue ->_M_addr 0xcb02bf8 > | `-CXXThisExpr 0xd1e2cb0 'struct std::__detail::__waiter_base<struct std::__detail::__waiter_pool> *' implicit this > |-IntegerLiteral 0xcb01098 'int' 5 > `-IntegerLiteral 0xcb01078 'int' 1 > error: 'error' diagnostics seen but not expected: > File ~/gcc/trunk/inst/lib/gcc/x86_64-pc-linux-gnu/12.0.1/../../../../include/c++/12.0.1/bits/atomic_wait.h Line 312: oh dear, what can the matter be? [loplugin:singlevalfields] > File ~/gcc/trunk/inst/lib/gcc/x86_64-pc-linux-gnu/12.0.1/../../../../include/c++/12.0.1/bits/atomic_wait.h Line 312: oh dear, what can the matter be? [loplugin:singlevalfields] Change-Id: I71c43b482aaa0992b7ce131d27e262b8e3b4087f Reviewed-on: https://gerrit.libreoffice.org/c/core/+/132160 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'compilerplugins')
-rw-r--r--compilerplugins/clang/singlevalfields.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/compilerplugins/clang/singlevalfields.cxx b/compilerplugins/clang/singlevalfields.cxx
index 3d966c9e9be3..df5abcc007b6 100644
--- a/compilerplugins/clang/singlevalfields.cxx
+++ b/compilerplugins/clang/singlevalfields.cxx
@@ -418,7 +418,7 @@ void SingleValFields::walkPotentialAssign( const DeclaratorDecl* fieldOrVarDecl,
{
break;
}
- else if ( isa<ArrayInitLoopExpr>(parent) || isa<GCCAsmStmt>(parent) || isa<VAArgExpr>(parent))
+ else if ( isa<ArrayInitLoopExpr>(parent) || isa<AtomicExpr>(parent) || isa<GCCAsmStmt>(parent) || isa<VAArgExpr>(parent))
{
bPotentiallyAssignedTo = true;
break;