| 1 |
/* { dg-do compile } */ |
| 2 |
/* { dg-additional-options "-fsyntax-only" } */ |
| 3 |
|
| 4 |
@interface MyRoot |
| 5 |
{ |
| 6 |
Class isa __attribute__((deprecated)); |
| 7 |
id p; |
| 8 |
int x; |
| 9 |
int *i; |
| 10 |
} |
| 11 |
|
| 12 |
@property(null_unspecified, assign) MyRoot *p1; |
| 13 |
@property(nonnull, assign) MyRoot *p2; |
| 14 |
@property(nullable, assign) MyRoot *p3; |
| 15 |
@property(null_resettable, assign) MyRoot *p4; |
| 16 |
@property(null_exciting, assign) MyRoot *e_5; /* { dg-error {unknown property attribute 'null_exciting'} } */ |
| 17 |
|
| 18 |
@property(nonnull, retain, nullable) MyRoot *e_6; /* { dg-error {'nullable' attribute conflicts with 'nonnull' attribute} } */ |
| 19 |
@property(nonnull, nonnull) int *i; /* { dg-warning {duplicate 'nonnull' attribute} } */ |
| 20 |
|
| 21 |
@end |