diff options
Diffstat (limited to 'gcc/testsuite/objc.dg/next-runtime-1.m')
-rw-r--r-- | gcc/testsuite/objc.dg/next-runtime-1.m | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/gcc/testsuite/objc.dg/next-runtime-1.m b/gcc/testsuite/objc.dg/next-runtime-1.m new file mode 100644 index 000000000..c76b6166d --- /dev/null +++ b/gcc/testsuite/objc.dg/next-runtime-1.m @@ -0,0 +1,20 @@ +/* Test that the correct version number (6) is set in the module descriptor + when compiling for the NeXT runtime ABI=0 - and that the MODULE descriptor + is not emitted at all for ABI 2. */ +/* modified from a testcase added by: Ziemowit Laski <zlaski@apple.com> */ + +/* { dg-do compile { target *-*-darwin* } } */ +/* { dg-skip-if "" { *-*-* } { "-fgnu-runtime" } { "" } } */ +/* { dg-skip-if "" { *-*-* } { "-fobjc-abi-version=1" } { "" } } */ +/* { dg-options "-fobjc-abi-version=0" { target { *-*-darwin* && { ! lp64 } } } } */ + +@interface FooBar +- (void)boo; +@end + +@implementation FooBar +- (void)boo { } +@end + +/* { dg-final { scan-assembler "L_OBJC_Module:\n\[ \t\]*\.long\t6\n" { target { *-*-darwin* && { ! lp64 } } } } } */ +/* { dg-final { scan-assembler-not "L_OBJC_Module" { target { *-*-darwin* && { lp64 } } } } } */ |