// 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(),
+ QualType PrimaryClassPropertyT = Context.getCanonicalType(PIDecl->getType());
+ QualType ClassExtPropertyT = Context.getCanonicalType(PDecl->getType());
+ if (!isa<ObjCObjectPointerType>(PrimaryClassPropertyT) ||
+ !isa<ObjCObjectPointerType>(ClassExtPropertyT) ||
+ (!isObjCPointerConversion(ClassExtPropertyT, PrimaryClassPropertyT,
ConvertedType, IncompatibleObjC))
|| IncompatibleObjC) {
Diag(AtLoc,
return d.instance.path; // expected-error {{property 'path' cannot be found in forward class object 'MDAInstance'}}
}
+// rdar://20469452
+@interface UIView @end
+
+@interface FRFakeBannerView : UIView
+@end
+
+@interface FRAdCollectionViewCell
+@property (nonatomic, weak, readonly) UIView *bannerView;
+@end
+
+@interface FRAdCollectionViewCell ()
+
+@property (nonatomic, weak, readwrite) FRFakeBannerView *bannerView;
+
+@end