[Bug c++/94529] [8/9/10/11 Regression] Wrong error message for template member function specialization
cvs-commit at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Thu Apr 8 11:59:08 GMT 2021
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94529
--- Comment #3 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Jason Merrill <jason@gcc.gnu.org>:
https://gcc.gnu.org/g:ac24fa46e449fbff0ff571951cfcc78b8488f6e7
commit r11-8042-gac24fa46e449fbff0ff571951cfcc78b8488f6e7
Author: Jason Merrill <jason@redhat.com>
Date: Thu Apr 8 01:03:28 2021 -0400
c++: improve specialization mismatch diagnostic [PR94529]
We were telling users they needed more template<> to specialize a member
template in a testcase with no member templates. Only produce that message
if we actually see a member template, and also always print the candidates.
gcc/cp/ChangeLog:
PR c++/94529
* pt.c (determine_specialization): Improve diagnostic.
gcc/testsuite/ChangeLog:
PR c++/94529
* g++.dg/template/mem-spec2.C: New test.
More information about the Gcc-bugs
mailing list