diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2017-09-28 18:31:53 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2017-09-28 18:31:53 +0200 |
commit | 812ee8c53f9add746f67e4785831ad0d42937942 (patch) | |
tree | 25f5c562c6f09f488933bbb036a1d8ae2993626b /compilerplugins/clang | |
parent | 8457b50ffd6e41b4925aef17bed2b5a2f3bf56bd (diff) |
Look through derived-to-base ImpliciCast
...as happens on Windows when looking at
maControlToPropertyMap.clear();
in PrintDialog::dispose (vcl/source/window/printdlg.cxx), where std::map's clear
happens to be declared at some base class std::_Tree.
Change-Id: I41810514bca59af8b4f2812d9412ce6a8d43576c
Diffstat (limited to 'compilerplugins/clang')
-rw-r--r-- | compilerplugins/clang/vclwidgets.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compilerplugins/clang/vclwidgets.cxx b/compilerplugins/clang/vclwidgets.cxx index c7695cfb5722..1a9589d2e40d 100644 --- a/compilerplugins/clang/vclwidgets.cxx +++ b/compilerplugins/clang/vclwidgets.cxx @@ -569,8 +569,8 @@ static void findDisposeAndClearStatements(std::set<const FieldDecl*>& aVclPtrFie const MemberExpr *pCalleeMemberExpr = dyn_cast<MemberExpr>(pCallExpr->getCallee()); if (!pCalleeMemberExpr->getBase()) return; - if (!isa<MemberExpr>(pCalleeMemberExpr->getBase())) return; - const MemberExpr *pCalleeMemberExprBase = dyn_cast<MemberExpr>(pCalleeMemberExpr->getBase()); + const MemberExpr *pCalleeMemberExprBase = dyn_cast<MemberExpr>(pCalleeMemberExpr->getBase()->IgnoreImpCasts()); + if (pCalleeMemberExprBase == nullptr) return; const FieldDecl* xxx = dyn_cast_or_null<FieldDecl>(pCalleeMemberExprBase->getMemberDecl()); if (xxx) |