blob: 1a7fc9ce3ccf0c6bc29339cb40eeacc4a86f5f34 [file] [log] [blame]
Fariborz Jahanian4b6df3f2007-10-04 00:22:33 +00001// RUN: clang -fsyntax-only -verify %s
2
Fariborz Jahanian894c57f2007-09-21 15:40:54 +00003@interface INTF1 @end
4
5@protocol p1,p2,p3;
6
7@protocol p1;
8
9@protocol PROTO1
10- (INTF1<p1>*) meth;
11@end
12
Chris Lattnereacc3922008-07-26 03:47:43 +000013@protocol PROTO2<p1> // expected-warning {{cannot find protocol definition for 'p1'}}
Fariborz Jahanian894c57f2007-09-21 15:40:54 +000014@end
15
16@protocol p1 @end
17
18@protocol PROTO<p1>
19@end
20
21@protocol PROTO<p1> // expected-error {{duplicate protocol declaration of 'PROTO'}}
22@end
23
24@protocol PROTO3<p1, p1>
25@end
26
27@protocol p2 <p1>
28@end
29
Chris Lattnereacc3922008-07-26 03:47:43 +000030@protocol PROTO4 <p1, p2, PROTO, PROTO3, p3> // expected-warning {{cannot find protocol definition for 'p3'}}
Fariborz Jahanian894c57f2007-09-21 15:40:54 +000031@end