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++/106310] [12/13/14 Regression] lookup after this-> seems wrong for dependent lookup since r12-6754-g30f2c22def739211
Date: Wed, 26 Jul 2023 16:45:24 +0000	[thread overview]
Message-ID: <bug-106310-4-Rmh8IgdsNr@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-106310-4@http.gcc.gnu.org/bugzilla/>

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

--- Comment #9 from CVS Commits <cvs-commit at gcc dot gnu.org> ---
The trunk branch has been updated by Jason Merrill <jason@gcc.gnu.org>:

https://gcc.gnu.org/g:51b997ea1d07465cb0208c711975b545872a2d2b

commit r14-2799-g51b997ea1d07465cb0208c711975b545872a2d2b
Author: Jason Merrill <jason@redhat.com>
Date:   Wed Jul 26 10:39:34 2023 -0400

    c++: member vs global template [PR106310]

    For backward compatibility we still want to allow patterns like
    this->A<T>::foo, but the template keyword in a qualified name is
    specifically to specify that a dependent name is a template, so don't look
    in the enclosing scope at all.

    Also fix handling of dependent bases: if member lookup in the current
    instantiation fails and we have dependent bases, the lookup is dependent.
    We were already handling that for the case where lookup in the enclosing
    scope also fails, but we also want it to affect that lookup itself.

            PR c++/106310

    gcc/cp/ChangeLog:

            * parser.cc (cp_parser_template_name): Skip non-member
            lookup after the template keyword.
            (cp_parser_lookup_name): Pass down template_keyword_p.

    gcc/testsuite/ChangeLog:

            * g++.dg/template/template-keyword4.C: New test.

  parent reply	other threads:[~2023-07-26 16:45 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-14 23:46 [Bug c++/106310] New: Failure to resolve call to template member function in template base class lnicoara at thinkoid dot org
2022-07-14 23:50 ` [Bug c++/106310] " pinskia at gcc dot gnu.org
2022-07-14 23:53 ` pinskia at gcc dot gnu.org
2022-07-14 23:55 ` [Bug c++/106310] [12/13 Regregression] lookup after this-> seems wrong for dependent lookup pinskia at gcc dot gnu.org
2022-07-15  7:57 ` [Bug c++/106310] [12/13 Regregression] lookup after this-> seems wrong for dependent lookup since r12-6754-g30f2c22def739211 marxin at gcc dot gnu.org
2022-07-18  7:30 ` rguenth at gcc dot gnu.org
2023-05-08 12:25 ` rguenth at gcc dot gnu.org
2023-07-12  3:24 ` [Bug c++/106310] [12/13/14 " pinskia at gcc dot gnu.org
2023-07-12  3:24 ` pinskia at gcc dot gnu.org
2023-07-26 14:40 ` [Bug c++/106310] [12/13/14 Regression] " jason at gcc dot gnu.org
2023-07-26 16:45 ` cvs-commit at gcc dot gnu.org [this message]
2023-07-26 19:25 ` [Bug c++/106310] [12/13 " jason at gcc dot gnu.org
2023-08-11 21:21 ` cvs-commit at gcc dot gnu.org
2023-08-11 21:22 ` cvs-commit at gcc dot gnu.org
2023-08-11 21:24 ` jason at gcc dot gnu.org
2023-09-08  9:10 ` fw at gcc dot gnu.org
2023-09-08 20:27 ` mpolacek at gcc dot gnu.org
2023-09-11 20:03 ` [Bug c++/106310] [11/12/13 " jason at gcc dot gnu.org
2023-09-11 22:11 ` [Bug c++/106310] [11 " cvs-commit at gcc dot gnu.org
2023-09-11 22:11 ` jason at gcc dot gnu.org

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-106310-4-Rmh8IgdsNr@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).