Debian Codegraph @

gcc/testsuite/obj-c++.dg/method-3.mm

raw
1 /* Do not warn about "slightly" mismatched method signatures if
2 -Wstrict-selector-match is off. */
3
4 /* { dg-do compile } */
5 /* { dg-options "-Wno-strict-selector-match" } */
6 // { dg-additional-options "-Wno-objc-root-class" }
7
8 #include <objc/objc.h>
9
10 @interface Base
11 - (id) meth1: (Base *)arg1;
12 - (id) window;
13 @end
14
15 @interface Derived: Base
16 - (id) meth1: (Derived *)arg1;
17 - (Base *) window;
18 @end
19
20 void foo(void) {
21 id r;
22
23 [r meth1:r];
24 [r window];
25 }