summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.rfg/00324_02-.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.rfg/00324_02-.C')
-rwxr-xr-xgcc/testsuite/g++.old-deja/g++.rfg/00324_02-.C16
1 files changed, 16 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.rfg/00324_02-.C b/gcc/testsuite/g++.old-deja/g++.rfg/00324_02-.C
new file mode 100755
index 0000000..4055ba8
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.rfg/00324_02-.C
@@ -0,0 +1,16 @@
+// Another simple one. GCC corerctly gives errors for this code when the
+// - -pedantic-errors options is used. g++ doesn't.
+
+// Build don't link:
+
+void f (int i) { }
+
+void (*fp)(void);
+
+int i;
+
+void
+test ()
+{
+ i ? f : fp; // ERROR -
+}