diff options
Diffstat (limited to 'test/SemaObjC')
-rw-r--r-- | test/SemaObjC/arc-property-decl-attrs.m | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/test/SemaObjC/arc-property-decl-attrs.m b/test/SemaObjC/arc-property-decl-attrs.m index ee48d310edc0..7393f58199f9 100644 --- a/test/SemaObjC/arc-property-decl-attrs.m +++ b/test/SemaObjC/arc-property-decl-attrs.m @@ -225,3 +225,30 @@ __attribute__((objc_root_class)) @implementation TypeVsSetter @synthesize prop; // expected-note {{property synthesized here}} @end + +@protocol AutoStrongProp + +@property (nonatomic, readonly) NSObject *prop; + +@end + +@protocol AutoStrongProp_Internal <AutoStrongProp> + +// This property gets the 'strong' attribute automatically. +@property (nonatomic, readwrite) NSObject *prop; + +@end + +@interface SynthesizeWithImplicitStrongNoError : NSObject <AutoStrongProp> +@end + +@interface SynthesizeWithImplicitStrongNoError () <AutoStrongProp_Internal> + +@end + +@implementation SynthesizeWithImplicitStrongNoError + +// no error, 'strong' is implicit in the 'readwrite' property. +@synthesize prop = _prop; + +@end |