2 /* { dg-do compile } */
3 /* { dg-options "-Wunused-but-set-variable" } */
5 #import "../objc-obj-c++-shared/TestsuiteObject.m"
7 @interface obj : TestsuiteObject
12 - (void) setValue: (int)number;
15 @implementation obj : TestsuiteObject
17 - (int) value { return value; }
18 - (void) setValue: (int)number { value = number; }
24 obj *a; /* { dg-bogus "set but not used" } */
25 obj *b; /* { dg-bogus "set but not used" } */
26 obj *c; /* { dg-warning "set but not used" } */
32 [b setValue: [a value]];