diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-08-04 09:38:44 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-08-04 09:38:44 +0200 |
commit | a2052db259c71618b4d26fcaa559b64f37e9e1a1 (patch) | |
tree | 0840cf5d9765a88117ed2a25380ed94e2d726dca /compilerplugins | |
parent | c15b4cf39a74176cee64795129d76f411d2c0a69 (diff) |
Workaround for ObjCIvarDecl problem
Change-Id: I7eb0fccce4b8268e5d9559b2eb12778d0d288c6b
Diffstat (limited to 'compilerplugins')
-rw-r--r-- | compilerplugins/clang/refcounting.cxx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/compilerplugins/clang/refcounting.cxx b/compilerplugins/clang/refcounting.cxx index 460db1c42489..710880e34f66 100644 --- a/compilerplugins/clang/refcounting.cxx +++ b/compilerplugins/clang/refcounting.cxx @@ -50,6 +50,14 @@ public: bool VisitFieldDecl(const FieldDecl *); bool VisitVarDecl(const VarDecl *); + + bool WalkUpFromObjCIvarDecl(ObjCIvarDecl * decl) { + // Don't recurse into WalkUpFromFieldDecl, as VisitFieldDecl calls + // FieldDecl::getParent, which triggers an assertion at least with + // current trunk towards Clang 3.7 when the FieldDecl is actually an + // ObjCIvarDecl. + return VisitObjCIvarDecl(decl); + } }; bool BaseCheckNotSubclass(const CXXRecordDecl *BaseDefinition, void *p) { |