diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2011-06-22 16:36:45 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2011-06-22 16:36:45 +0000 |
commit | 8295b7b51b13add75518bb9e2d9db00711a20166 (patch) | |
tree | e08bec13b6c5f6a1fd9843aaf2f1c1d553d8f1cc /lib | |
parent | d1bd98a2c239d2a730b07f7c1b2c8c8718eaeac8 (diff) |
objc-arc: Allow unbridged cast of retainable object to
integral as it is not transferring ownership..
// rdar://9619861
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@133622 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib')
-rw-r--r-- | lib/Sema/SemaExprObjC.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Sema/SemaExprObjC.cpp b/lib/Sema/SemaExprObjC.cpp index 83b01f24a2..84ac897b37 100644 --- a/lib/Sema/SemaExprObjC.cpp +++ b/lib/Sema/SemaExprObjC.cpp @@ -1620,7 +1620,7 @@ Sema::CheckObjCARCConversion(SourceRange castRange, QualType castType, ARCConversionTypeClass exprACTC = classifyTypeForARCConversion(castExprType); ARCConversionTypeClass castACTC = classifyTypeForARCConversion(castType); if (exprACTC == castACTC) return; - if (exprACTC && castType->isBooleanType()) return; + if (exprACTC && castType->isIntegralType(Context)) return; // Allow casts between pointers to lifetime types (e.g., __strong id*) // and pointers to void (e.g., cv void *). Casting from void* to lifetime* |