1 /* Negative test case for constant string layout. */
2 /* Contributed by Ziemowit Laski <zlaski@apple.com>. */
4 /* { dg-do compile } */
5 /* { dg-options "-fconstant-string-class=MyConstantString" } */
6 /* { dg-options "-mno-constant-cfstrings -fconstant-string-class=MyConstantString" { target *-*-darwin* } } */
13 @interface MyConstantString: MyBase {
22 /* The NeXT runtime initializes the 'isa' pointer of string constants at
24 #ifdef __NEXT_RUNTIME__
25 extern void *_MyConstantStringClassReference;
28 MyConstantString *str = @"Hello"; /* { dg-error "interface .MyConstantString. does not have valid constant string layout" } */