summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.mike/asm2.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.mike/asm2.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.mike/asm2.C25
1 files changed, 25 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.mike/asm2.C b/gcc/testsuite/g++.old-deja/g++.mike/asm2.C
new file mode 100644
index 000000000..62ae86235
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.mike/asm2.C
@@ -0,0 +1,25 @@
+// { dg-do run }
+// Compile with -S, there should be no references to
+// LTRAMP in the output.
+
+extern "C" int printf (const char *, ...);
+
+void
+sub2 (void (*func) ())
+{
+ (*func) ();
+}
+
+int
+main(void)
+{
+ extern void sub (void);
+
+ sub2 (sub);
+}
+
+void
+sub (void)
+{
+ printf ("hello world\n");
+}