diff --git a/src/shared/cplusplus/Scope.cpp b/src/shared/cplusplus/Scope.cpp index 0fae6db39198ef369581ecb974cd7886d7759bb3..86503826d7f91bad0a1d0897f8626004aa0927ea 100644 --- a/src/shared/cplusplus/Scope.cpp +++ b/src/shared/cplusplus/Scope.cpp @@ -172,6 +172,13 @@ bool Scope::isPrototypeScope() const return false; } +bool Scope::isObjCClassScope() const +{ + if (_owner) + return _owner->isObjCClass(); + return false; +} + bool Scope::isFunctionScope() const { Function *f = 0; diff --git a/src/shared/cplusplus/Scope.h b/src/shared/cplusplus/Scope.h index 04f735bf2a6b620ffe3fcf9e8a43e042f64a4575..a31b6459be6c1d8b552d85b1bd24ca9de61f6256 100644 --- a/src/shared/cplusplus/Scope.h +++ b/src/shared/cplusplus/Scope.h @@ -111,6 +111,9 @@ public: /// Returns true if this scope's owner is a Prototype Symbol. bool isPrototypeScope() const; + /// Returns true if this scope's owner is an ObjCClass Symbol. + bool isObjCClassScope() const; + /// Adds a Symbol to this Scope. void enterSymbol(Symbol *symbol);