On Nov 18, 2013, at 4:15 PM, jahanian <[email protected]> wrote: > > On Nov 18, 2013, at 4:13 PM, Douglas Gregor <[email protected]> wrote: > >> >> On Nov 16, 2013, at 3:22 PM, Fariborz Jahanian <[email protected]> wrote: >> >>> > >>> -void Test2(CFErrorRef2 cf, NSError *ns, NSString *str) { >>> +void Test2(CFErrorRef2 cf, NSError *ns, NSString *str, Class c) { >>> (void)(NSString *)cf; // expected-warning {{CFErrorRef bridges to NSError, >>> not NSString}} >>> (void)(NSError *)cf; // okay >>> (void)(MyError*)cf; // okay, >>> (void)(CFErrorRef)ns; // okay >>> (void)(CFErrorRef)str; // expected-warning {{NSString cannot bridge to >>> CFErrorRef}} >>> + (void)(Class)cf; // expected-warning {{CFErrorRef bridges to NSError, >>> not 'Class'}} >>> + (void)(CFErrorRef)c; // expected-warning {{'Class' cannot bridge to >>> 'CFErrorRef’}} >> >> ‘Class’ behaves like ‘id’, doesn’t it? Shouldn’t these be accepted without a >> warning? > > Ok. Just that I wasn’t sure and I wanted to be on the cautious side.
Jordan, raised a question. So, I wait. - Fariborz > _______________________________________________ > cfe-commits mailing list > [email protected] > http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits _______________________________________________ cfe-commits mailing list [email protected] http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits
