diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2011-09-07 00:38:49 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2011-09-07 00:38:49 +0000 |
commit | 9a776695e9f3831e59519fd45d130bff20456d7a (patch) | |
tree | c889a8f2632619acf470c9cab299f48ac8a37fa2 /lib/Sema/SemaObjCProperty.cpp | |
parent | 0f74d1e441fdf2229118b7ca5c88db29d5e8f44f (diff) |
objc-gc: Don't force a __strong type'd property
to be 'weak'. This prevents a crash and should
probably be flagged as error - later to come.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@139211 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Sema/SemaObjCProperty.cpp')
-rw-r--r-- | lib/Sema/SemaObjCProperty.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaObjCProperty.cpp b/lib/Sema/SemaObjCProperty.cpp index bf4939d9fd..9695b811ee 100644 --- a/lib/Sema/SemaObjCProperty.cpp +++ b/lib/Sema/SemaObjCProperty.cpp @@ -598,7 +598,7 @@ Decl *Sema::ActOnPropertyImplDecl(Scope *S, !getLangOptions().ObjCAutoRefCount && getLangOptions().getGCMode() != LangOptions::NonGC); - if (PropertyIsGCWeak) + if (PropertyIsGCWeak && !PropType.isObjCGCStrong()) PropType = Context.getObjCGCQualType(PropType, Qualifiers::Weak); QualType PropertyIvarType = PropType; if (PropType->isReferenceType()) |