public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "cvs-commit at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/108179] [11/12 regression] ICE related to template template parameters in tsubst, at cp/pt.cc:15782
Date: Mon, 07 Aug 2023 23:27:03 +0000	[thread overview]
Message-ID: <bug-108179-4-rDtdlN0i9l@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-108179-4@http.gcc.gnu.org/bugzilla/>

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

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

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

commit r13-7692-g2c6e76ff039782401f705cacda60c11f8dfac3b1
Author: Patrick Palka <ppalka@redhat.com>
Date:   Wed Jul 26 17:21:26 2023 -0400

    c++: passing partially inst tmpl as ttp [PR110566]

    Since the template arguments 'pargs' we pass to coerce_template_parms from
    coerce_template_template_parms are always a full set, we need to make sure
    we always pass the parameters of the most general template because if the
    template is partially instantiated then the levels won't match up.  In the
    testcase below during said call to coerce_template_parms the parameters are
    {X, Y}, both level 1 rather than 2, and the arguments are {{int}, {N, M}},
    which results in a crash during auto deduction for parameters' types.

            PR c++/110566
            PR c++/108179

    gcc/cp/ChangeLog:

            * pt.cc (coerce_template_template_parms): Simplify by using
            DECL_INNERMOST_TEMPLATE_PARMS and removing redundant asserts.
            Always pass the parameters of the most general template to
            coerce_template_parms.

    gcc/testsuite/ChangeLog:

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

    (cherry picked from commit b3adcc60dcf3314f47f5409aecef40607f82b80b)

      parent reply	other threads:[~2023-08-07 23:27 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-12-19 16:11 [Bug c++/108179] New: " s at stu dot scot
2022-12-19 16:22 ` [Bug c++/108179] [11/12/13 " pinskia at gcc dot gnu.org
2022-12-19 16:28 ` pinskia at gcc dot gnu.org
2022-12-21 12:44 ` rguenth at gcc dot gnu.org
2022-12-21 15:39 ` ppalka at gcc dot gnu.org
2023-03-10 18:52 ` jason at gcc dot gnu.org
2023-03-15 12:45 ` cvs-commit at gcc dot gnu.org
2023-03-15 12:45 ` cvs-commit at gcc dot gnu.org
2023-03-15 12:47 ` [Bug c++/108179] [11/12 " jason at gcc dot gnu.org
2023-03-15 12:55 ` s at stu dot scot
2023-04-22  0:31 ` jason at gcc dot gnu.org
2023-05-29 10:07 ` jakub at gcc dot gnu.org
2023-07-20  1:10 ` jason at gcc dot gnu.org
2023-07-26 21:22 ` cvs-commit at gcc dot gnu.org
2023-07-26 21:22 ` cvs-commit at gcc dot gnu.org
2023-08-07 23:27 ` cvs-commit at gcc dot gnu.org [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-108179-4-rDtdlN0i9l@http.gcc.gnu.org/bugzilla/ \
    --to=gcc-bugzilla@gcc.gnu.org \
    --cc=gcc-bugs@gcc.gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).