Author: fjahanian
Date: Thu Feb 2 16:37:48 2012
New Revision: 149639
URL: http://llvm.org/viewvc/llvm-project?rev=149639&view=rev
Log:
Further enhance comment for property in continuation class.
Modified:
cfe/trunk/lib/Sema/SemaObjCProperty.cpp
Modified: cfe/trunk/lib/Sema/SemaObjCProperty.cpp
URL:
http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaObjCProperty.cpp?rev=149639&r1=149638&r2=149639&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaObjCProperty.cpp (original)
+++ cfe/trunk/lib/Sema/SemaObjCProperty.cpp Thu Feb 2 16:37:48 2012
@@ -281,7 +281,10 @@
QualType ConvertedType;
// Relax the strict type matching for property type in continuation class.
// Allow property object type of continuation class to be different as long
- // as it narrows the object type in its primary class property.
+ // as it narrows the object type in its primary class property. Note that
+ // this conversion is safe only because the wider type is for a 'readonly'
+ // property in primary class and 'narrowed' type for a 'readwrite' property
+ // in continuation class.
if (!isa<ObjCObjectPointerType>(PIDecl->getType()) ||
!isa<ObjCObjectPointerType>(PDecl->getType()) ||
(!isObjCPointerConversion(PDecl->getType(), PIDecl->getType(),
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits