aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.old-deja/g++.brendan/redecl3.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.old-deja/g++.brendan/redecl3.C')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.brendan/redecl3.C17
1 files changed, 17 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.brendan/redecl3.C b/gcc/testsuite/g++.old-deja/g++.brendan/redecl3.C
new file mode 100644
index 00000000000..5987e0e3172
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.brendan/redecl3.C
@@ -0,0 +1,17 @@
+// Build don't link:
+// GROUPS passed redeclaration
+class foo
+{
+public:
+ int bar(int a);
+};
+
+
+void bar(int &a);
+
+int foo::bar(int a) {
+ int a = 0; // Should this be an error ?// ERROR - declaration.*
+
+ bar(a);
+ return 0;
+}