diff options
Diffstat (limited to 'clang/lib/AST/DeclObjC.cpp')
-rw-r--r-- | clang/lib/AST/DeclObjC.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/clang/lib/AST/DeclObjC.cpp b/clang/lib/AST/DeclObjC.cpp index 4d2fcb69ac7..855764fdbd3 100644 --- a/clang/lib/AST/DeclObjC.cpp +++ b/clang/lib/AST/DeclObjC.cpp @@ -137,6 +137,16 @@ ObjCIvarDecl *ObjCInterfaceDecl::lookupInstanceVariable( return *I; } } + // look into properties. + for (ObjCInterfaceDecl::prop_iterator I = ClassDecl->prop_begin(), + E = ClassDecl->prop_end(); I != E; ++I) { + ObjCPropertyDecl *PDecl = (*I); + if (ObjCIvarDecl *IV = PDecl->getPropertyIvarDecl()) + if (IV->getIdentifier() == ID) { + clsDeclared = ClassDecl; + return IV; + } + } ClassDecl = ClassDecl->getSuperClass(); } return NULL; |