diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2010-10-14 21:30:10 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2010-10-14 21:30:10 +0000 |
commit | fa432391a708448518df1e6ced4e34f4c349d169 (patch) | |
tree | f1fc9aa9ea41106caf991387d38121c2444172ce /test/SemaObjCXX/property-synthesis-error.mm | |
parent | ed7c308fac03da7168e167de15d231af8aed02a6 (diff) |
Put line number on the diagnostic. //rdar: //8550657.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@116519 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/SemaObjCXX/property-synthesis-error.mm')
-rw-r--r-- | test/SemaObjCXX/property-synthesis-error.mm | 32 |
1 files changed, 32 insertions, 0 deletions
diff --git a/test/SemaObjCXX/property-synthesis-error.mm b/test/SemaObjCXX/property-synthesis-error.mm new file mode 100644 index 0000000000..59e17b2a8d --- /dev/null +++ b/test/SemaObjCXX/property-synthesis-error.mm @@ -0,0 +1,32 @@ +// RUN: %clang_cc1 -fsyntax-only -verify %s +// rdar: //8550657 + +@interface NSArray @end + +@interface NSMutableArray : NSArray @end + +@interface MyClass +{ + NSMutableArray * _array; +} + +@property (readonly) NSArray * array; + +@end + +@interface MyClass () + +@property (readwrite) NSMutableArray * array; + +@end + +@implementation MyClass + +@synthesize array=_array; // expected-error {{assigning to 'NSMutableArray *' from incompatible type 'NSArray *'}} + +@end + +int main(void) +{ + return 0; +} |