summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.other/linkage2.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.other/linkage2.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.other/linkage2.C14
1 files changed, 14 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.other/linkage2.C b/gcc/testsuite/g++.old-deja/g++.other/linkage2.C
new file mode 100644
index 000000000..2385b2216
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.other/linkage2.C
@@ -0,0 +1,14 @@
+// { dg-do assemble }
+// From: Klaus-Georg Adams <Klaus-Georg.Adams@chemie.uni-karlsruhe.de>
+extern "C"
+{
+typedef struct {int dummy[10];} *GDBM_FILE;
+extern GDBM_FILE gdbm_open();
+}
+
+typedef struct { int dummy[10]; } *FAIL_FILE;
+extern FAIL_FILE fail_open(); // { dg-error "" } non-local function
+
+typedef struct { int dummy[10]; } *SUCCESS_FILE, S;
+extern SUCCESS_FILE success_open();
+