aboutsummaryrefslogtreecommitdiffstats
path: root/gcc-4.9/gcc/testsuite/g++.dg/other/default2.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc-4.9/gcc/testsuite/g++.dg/other/default2.C')
-rw-r--r--gcc-4.9/gcc/testsuite/g++.dg/other/default2.C9
1 files changed, 9 insertions, 0 deletions
diff --git a/gcc-4.9/gcc/testsuite/g++.dg/other/default2.C b/gcc-4.9/gcc/testsuite/g++.dg/other/default2.C
new file mode 100644
index 000000000..51534b887
--- /dev/null
+++ b/gcc-4.9/gcc/testsuite/g++.dg/other/default2.C
@@ -0,0 +1,9 @@
+// PR c++/16829
+// { dg-do compile }
+
+template<typename T> void foo(T, int = 0, int) {} // { dg-error "default" }
+
+void bar()
+{
+ foo(0);
+}