blob: f1bda094c2db2ec4edc05abe3439fc14cfd5ea75 [file] [log] [blame]
Fariborz Jahanian2514a302009-12-15 23:59:41 +00001// RUN: %clang_cc1 -fsyntax-only -verify %s
2
3typedef struct NSSize {
4 int width;
5 struct {
6 int dim;
7 } inner;
8} NSSize;
9
10@interface Foo {
11 NSSize _size;
12}
13@property NSSize size;
14@end
15
16void foo() {
17 Foo *f;
18 f.size.width = 2.2; // expected-error {{cannot assign to a sub-structure of an ivar using property assignment syntax}}
19 f.size.inner.dim = 200; // expected-error {{cannot assign to a sub-structure of an ivar using property assignment syntax}}
20}