| 1 |
// RUN: %clang_cc1 -fsyntax-only -verify %s |
| 2 |
// expected-no-diagnostics |
| 3 |
|
| 4 |
@protocol P1; |
| 5 |
|
| 6 |
@interface NSObject |
| 7 |
@end |
| 8 |
|
| 9 |
@interface A : NSObject |
| 10 |
@property (assign) NSObject<P1> *prop; |
| 11 |
@end |
| 12 |
|
| 13 |
@protocol P2 <P1> |
| 14 |
@end |
| 15 |
|
| 16 |
@interface B : A |
| 17 |
@property (assign) NSObject<P2> *prop; |
| 18 |
@end |
| 19 |
|
| 20 |
@interface C<T> : NSObject |
| 21 |
@end |
| 22 |
|
| 23 |
@interface D |
| 24 |
@property (nonatomic,readonly,nonnull) C<D *> *property; |
| 25 |
@end |
| 26 |
|
| 27 |
@interface D () |
| 28 |
@property (nonatomic, setter=_setProperty:) C *property; // okay |
| 29 |
@end |