summaryrefslogtreecommitdiff
path: root/compilerplugins/clang/check.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'compilerplugins/clang/check.cxx')
-rw-r--r--compilerplugins/clang/check.cxx4
1 files changed, 2 insertions, 2 deletions
diff --git a/compilerplugins/clang/check.cxx b/compilerplugins/clang/check.cxx
index 7be98bf97d5c..4ff081b6923e 100644
--- a/compilerplugins/clang/check.cxx
+++ b/compilerplugins/clang/check.cxx
@@ -374,10 +374,10 @@ static bool BaseCheckNotSubclass(const clang::CXXRecordDecl *BaseDefinition, voi
return true;
}
-bool isDerivedFrom(const clang::CXXRecordDecl *decl, DeclChecker base) {
+bool isDerivedFrom(const clang::CXXRecordDecl *decl, DeclChecker base, bool checkSelf) {
if (!decl)
return false;
- if (base(decl))
+ if (checkSelf && base(decl))
return true;
if (!decl->hasDefinition()) {
return false;