c++: premature overload resolution redux [PR100078]
authorJason Merrill <jason@redhat.com>
Wed, 14 Apr 2021 18:14:31 +0000 (14:14 -0400)
committerJason Merrill <jason@redhat.com>
Wed, 14 Apr 2021 18:14:31 +0000 (14:14 -0400)
commit00a2774923c1dc5666cd26bb9b8c37b1b7dd689d
tree7f76425ef73fdd11642b93a8b3ece8e49382488e
parent9b53edc796d284b6adec7f2996772dbddf4c341e
c++: premature overload resolution redux [PR100078]

My patch for PR93085 didn't consider that a default template argument can
also make a template dependent.

gcc/cp/ChangeLog:

PR c++/100078
PR c++/93085
* pt.c (uses_outer_template_parms): Also look at default
template argument.

gcc/testsuite/ChangeLog:

PR c++/100078
* g++.dg/template/dependent-tmpl2.C: New test.
gcc/cp/pt.c
gcc/testsuite/g++.dg/template/dependent-tmpl2.C [new file with mode: 0644]