summaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authormmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>1998-03-30 12:17:01 +0000
committermmitchel <mmitchel@138bc75d-0d04-0410-961f-82ee72b054a4>1998-03-30 12:17:01 +0000
commitffe183cac0751b2101e38ea9baffd603ef0d822f (patch)
tree08ca0bc571598c2548204f0b3ea2452c06f8a88e /gcc/testsuite
parent1486870d76c8ec5ab28664fa7dcadd8ccc5e9723 (diff)
downloadgcc-ffe183cac0751b2101e38ea9baffd603ef0d822f.tar.gz
* pt.c (fn_type_unification): Allow incomplete unification without
an immediate error message. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@18912 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/g++.old-deja/g++.pt/unify2.C27
1 files changed, 27 insertions, 0 deletions
diff --git a/gcc/testsuite/g++.old-deja/g++.pt/unify2.C b/gcc/testsuite/g++.old-deja/g++.pt/unify2.C
new file mode 100644
index 00000000000..89b043d7901
--- /dev/null
+++ b/gcc/testsuite/g++.old-deja/g++.pt/unify2.C
@@ -0,0 +1,27 @@
+// Build don't link:
+
+template <class T>
+struct S
+{
+ typedef T S_Type;
+};
+
+
+template <class T>
+void foo(typename S<T>::S_Type)
+{
+}
+
+
+template <class T>
+void foo(T)
+{
+}
+
+
+struct S2 {};
+
+void bar()
+{
+ foo(S2()); // We can't unify with the first foo, so we get the second.
+}