Fix more rewriting of protocol-quialified 'id' type.
(Fixes radar 7607413). llvm-svn: 95257
This commit is contained in:
parent
f914be06d2
commit
80c54b05a0
|
|
@ -1995,6 +1995,8 @@ static void scanToNextArgument(const char *&argRef) {
|
|||
}
|
||||
|
||||
bool RewriteObjC::needToScanForQualifiers(QualType T) {
|
||||
if (T->isObjCQualifiedIdType())
|
||||
return true;
|
||||
if (const PointerType *PT = T->getAs<PointerType>()) {
|
||||
if (PT->getPointeeType()->isObjCQualifiedIdType())
|
||||
return true;
|
||||
|
|
|
|||
|
|
@ -16,6 +16,26 @@
|
|||
}
|
||||
@end
|
||||
|
||||
// radar 7607413
|
||||
@protocol Proto1, Proto2;
|
||||
|
||||
@protocol Proto
|
||||
@end
|
||||
|
||||
unsigned char func(id<Proto1, Proto2> inProxy);
|
||||
|
||||
id bar(id);
|
||||
|
||||
void f() {
|
||||
id a;
|
||||
id b = bar((id <Proto>)a);
|
||||
}
|
||||
|
||||
// CHECK-LP: NSConnection /*<NSPortDelegate>*/ *conn = 0;
|
||||
|
||||
// CHECK-LP: id /*<NSPortDelegate>*/ *idc = 0;
|
||||
|
||||
// CHECK-LP: func(id/*<Proto1, Proto2>*/ inProxy);
|
||||
|
||||
// CHECK-LP: bar((id /*<Proto>*/)a);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue