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

--- Comment #10 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The master branch has been updated by Patrick Palka <ppa...@gcc.gnu.org>:

https://gcc.gnu.org/g:2c60368ab5706a870a1a3be190acc4d673672c30

commit r14-2421-g2c60368ab5706a870a1a3be190acc4d673672c30
Author: Patrick Palka <ppa...@redhat.com>
Date:   Mon Jul 10 10:59:40 2023 -0400

    c++: redeclare_class_template and ttps [PR110523]

    Now that we cache level-lowered ttps we can end up processing the same
    ttp multiple times via (multiple calls to) redeclare_class_template, so
    we can't assume a ttp's DECL_CONTEXT is initially empty.

            PR c++/110523

    gcc/cp/ChangeLog:

            * pt.cc (redeclare_class_template): Relax the ttp DECL_CONTEXT
            assert, and downgrade it to a checking assert.

    gcc/testsuite/ChangeLog:

            * g++.dg/template/ttp37.C: New test.

Reply via email to