aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/objc.dg/next-runtime-1.m
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/objc.dg/next-runtime-1.m')
-rw-r--r--gcc/testsuite/objc.dg/next-runtime-1.m18
1 files changed, 18 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 00000000000..1fbf70a27d7
--- /dev/null
+++ b/gcc/testsuite/objc.dg/next-runtime-1.m
@@ -0,0 +1,18 @@
+/* APPLE LOCAL file ObjC GC */
+/* Test that the correct version number (6) is set in the module descriptor
+ when compiling for the NeXT runtime. */
+/* Author: Ziemowit Laski <zlaski@apple.com> */
+/* { dg-do compile { target *-*-darwin* } } */
+/* { dg-options "-fnext-runtime" } */
+
+#include <objc/Object.h>
+
+@interface FooBar: Object
+- (void)boo;
+@end
+
+@implementation FooBar
+- (void)boo { }
+@end
+
+/* { dg-final { scan-assembler "L_OBJC_MODULES:\n\[ \t\]*\.long\t6\n" } } */