aboutsummaryrefslogtreecommitdiffstats
path: root/test/MC/MachO/eh-symbols.s
diff options
context:
space:
mode:
Diffstat (limited to 'test/MC/MachO/eh-symbols.s')
-rw-r--r--test/MC/MachO/eh-symbols.s25
1 files changed, 25 insertions, 0 deletions
diff --git a/test/MC/MachO/eh-symbols.s b/test/MC/MachO/eh-symbols.s
new file mode 100644
index 0000000..6adca56
--- /dev/null
+++ b/test/MC/MachO/eh-symbols.s
@@ -0,0 +1,25 @@
+// RUN: llvm-mc -filetype=obj -triple i686-apple-darwin %s -o - | llvm-readobj -t | FileCheck %s
+
+// Make sure that the exception handling data has the same visibility as the
+// function it's generated for.
+
+ .private_extern _main
+ .globl _main
+_main:
+ .cfi_startproc
+ retl
+ .cfi_endproc
+
+"_-[NSString(local) isNullOrNil]":
+ .cfi_startproc
+ retl
+ .cfi_endproc
+
+// CHECK: Name: _-[NSString(local) isNullOrNil].eh
+
+// CHECK: Name: _main
+// CHECK-NEXT: PrivateExtern
+
+// CHECK: Name: _main.eh
+// CHECK-NEXT: PrivateExtern
+