[Bug c++/122668] [15/16 regression] error: 'class TestClass<T>' has no member named 'member_function' [-Wtemplate-body]

cvs-commit at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Tue Dec 16 15:33:25 GMT 2025


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=122668

--- Comment #6 from GCC Commits <cvs-commit at gcc dot gnu.org> ---
The releases/gcc-15 branch has been updated by Patrick Palka
<ppalka@gcc.gnu.org>:

https://gcc.gnu.org/g:44eb6711f9b38e84d0e3721aa8356b8ffc5d5939

commit r15-10608-g44eb6711f9b38e84d0e3721aa8356b8ffc5d5939
Author: Patrick Palka <ppalka@redhat.com>
Date:   Wed Nov 19 11:10:38 2025 -0500

    c++: current inst name lookup within noexcept-spec [PR122668]

    Since we don't implement deferred noexcept-spec parsing of a friend
    declaration, the r15-2117 change diagnosing name lookup failure for the
    current instantiation ahead of time needs to be suppressed in this case.

            PR c++/122668
            PR c++/114764

    gcc/cp/ChangeLog:

            * pt.cc (dependentish_scope_p): Return true for the current
            instantiation from within an immediately parsed noexcept-spec.

    gcc/testsuite/ChangeLog:

            * g++.dg/cpp0x/noexcept91.C: New test.

    Reviewed-by: Jason Merrill <jason@redhat.com>
    (cherry picked from commit 6b7f4b587b5cb95ea3ed2f543841a3d1ed6f580d)


More information about the Gcc-bugs mailing list