PR inline-asm/84742
[official-gcc.git] / gcc / testsuite / objc.dg / encode-6.m
blob291a41e96a0a783f1055ab8a502aa5c21c360bdb
1 /* Test for graceful encoding of const-qualified fields and parameters.  */
2 /* Author: Ziemowit Laski  <zlaski@apple.com>  */
3 /* { dg-do compile } */
4 /* { dg-skip-if "" { *-*-* } { "-fnext-runtime" } { "" } } */
6 struct Cxx {
7   const struct Cxx *next;
8 };
10 @interface ObjC {
11   const struct Cxx *obj;
13 - (ObjC *)initWithCxx: (struct Cxx *const)c and: (const struct Cxx *)d;
14 @end
16 @implementation ObjC
17 - (ObjC *)initWithCxx: (struct Cxx *const)c and: (const struct Cxx *)d {
18   obj = d;
19   return self;
21 @end 
23 /* { dg-final { scan-assembler "@\[0-9\]+@0:\[0-9\]+r\\^{Cxx=\\^r{Cxx}}\[0-9\]+\\^r{Cxx}" } } */