summaryrefslogtreecommitdiff
path: root/gcc/testsuite/g++.dg/overload/koenig2.C
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/testsuite/g++.dg/overload/koenig2.C')
-rw-r--r--gcc/testsuite/g++.dg/overload/koenig2.C15
1 files changed, 15 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.dg/overload/koenig2.C b/gcc/testsuite/g++.dg/overload/koenig2.C
new file mode 100644
index 000000000..f35aa1a31
--- /dev/null
+++ b/gcc/testsuite/g++.dg/overload/koenig2.C
@@ -0,0 +1,15 @@
+// Copyright (C) 2005 Free Software Foundation, Inc.
+// Contributed by Nathan Sidwell 18 Oct 2005 <nathan@codesourcery.com>
+
+// PR 21383
+// Origin: Matthew Hall <mahall@ncsa.uiuc.edu>
+
+template <class T>
+void dummy(T& t);
+
+void anyfunc(int x);
+
+void Foo ()
+{
+ anyfunc (&dummy<>); // { dg-error "cannot resolve overload" "" }
+}