diff options
author | Ted Kremenek <kremenek@apple.com> | 2010-12-23 21:35:43 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2010-12-23 21:35:43 +0000 |
commit | c32647d111e516593b9ba242cad7b8ff4016c155 (patch) | |
tree | 94ffd2ac21a9e0113f2cc190cedcd8eea25b1033 /lib/Sema/SemaDeclObjC.cpp | |
parent | 21142581d55918beed544a757e4af3bb865b1812 (diff) |
Add -fobjc-default-synthesized-properties flag
to allow us to explicitly control whether or
not Objective-C properties are default synthesized.
Currently this feature only works when using
the -fobjc-non-fragile-abi2 flag (so there is
no functionality change), but we can now turn
off this feature without turning off all the features
coupled with -fobjc-non-fragile-abi2.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@122519 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaDeclObjC.cpp')
-rw-r--r-- | lib/Sema/SemaDeclObjC.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/Sema/SemaDeclObjC.cpp b/lib/Sema/SemaDeclObjC.cpp index d19991138e..8c66588da2 100644 --- a/lib/Sema/SemaDeclObjC.cpp +++ b/lib/Sema/SemaDeclObjC.cpp @@ -1095,7 +1095,8 @@ void Sema::ImplMethodsVsClassMethods(Scope *S, ObjCImplDecl* IMPDecl, // Check and see if properties declared in the interface have either 1) // an implementation or 2) there is a @synthesize/@dynamic implementation // of the property in the @implementation. - if (isa<ObjCInterfaceDecl>(CDecl) && !LangOpts.ObjCNonFragileABI2) + if (isa<ObjCInterfaceDecl>(CDecl) && + !(LangOpts.ObjCDefaultSynthProperties && LangOpts.ObjCNonFragileABI2)) DiagnoseUnimplementedProperties(S, IMPDecl, CDecl, InsMap); llvm::DenseSet<Selector> ClsMap; @@ -1587,7 +1588,8 @@ void Sema::ActOnAtEnd(Scope *S, SourceRange AtEnd, } } - if (LangOpts.ObjCNonFragileABI2) + if (LangOpts.ObjCDefaultSynthProperties && + LangOpts.ObjCNonFragileABI2) DefaultSynthesizeProperties(S, IC, IDecl); ImplMethodsVsClassMethods(S, IC, IDecl); AtomicPropertySetterGetterRules(IC, IDecl); |