[Bug c++/105964] [12 Regression] Return type deduction fails during NTTP use of function dependent on template parameter

cvs-commit at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Thu Jun 23 03:46:55 GMT 2022


--- Comment #4 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-12 branch has been updated by Jason Merrill


commit r12-8507-gc85cea9ca165b0b771d9f913016c9dc8db46b5d7
Author: Jason Merrill <jason@redhat.com>
Date:   Wed Jun 22 18:19:11 2022 -0400

    c++: dependence of baselink [PR105964]

    helper<token>::c isn't dependent just because we haven't deduced its return
    type yet.  type_dependent_expression_p already knows how to deal with that
    for bare FUNCTION_DECL, but needs to learn to look through a BASELINK.

            PR c++/105964


            * pt.cc (type_dependent_expression_p): Look through BASELINK.


            * g++.dg/cpp1z/nontype-auto21.C: New test.

More information about the Gcc-bugs mailing list