diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2009-04-06 16:59:10 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2009-04-06 16:59:10 +0000 |
commit | 50efe0483563b12dc8e005068c85d68dc1f7d9ae (patch) | |
tree | 1fdbf1e7e19e53fe2d29d19b78c9f5e020d51863 /lib/Sema/SemaDeclObjC.cpp | |
parent | b02e53b5a859f12ad1e3f90a22b6fb711901a172 (diff) |
writable property in a category of class's superclass
makes the property writable in the current class.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@68446 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDeclObjC.cpp')
-rw-r--r-- | lib/Sema/SemaDeclObjC.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Sema/SemaDeclObjC.cpp b/lib/Sema/SemaDeclObjC.cpp index 299f101bdb..80d46bcabb 100644 --- a/lib/Sema/SemaDeclObjC.cpp +++ b/lib/Sema/SemaDeclObjC.cpp @@ -835,6 +835,9 @@ bool Sema::isPropertyReadonly(ObjCPropertyDecl *PDecl, ObjCImplementations[IDecl->getIdentifier()]) if (ImpDecl->getInstanceMethod(PDecl->getSetterName())) return false; + // If all fails, look at the super class. + if (ObjCInterfaceDecl *SIDecl = IDecl->getSuperClass()) + return isPropertyReadonly(PDecl, SIDecl); return true; } |