From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 9EDC03858D32; Wed, 12 Apr 2023 06:02:32 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 9EDC03858D32 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1681279352; bh=imKK6521RlSQfAc+1f0zqPZhcefRGEsjavv3lXlmJso=; h=From:To:Subject:Date:In-Reply-To:References:From; b=hnbFgjvKNsM8lcESxY/f473XwX6Fo85pBzO0wwGIEJ3hynF79QBopp5/3c0YYVMMN 1TvrDgZAd0XKu7XSrUu/FGMdjdy/yYuF4jwPy5Ahovp+YfDEY5x8OAW6G5V/QmilsW JnlfSh2lEUbfzk8LR3ycDr7/W1x2zi3njFD3eOs0= From: "pinskia at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/109480] [11/12/13 Regression] non-depedent access goes wrong in a template method sometimes Date: Wed, 12 Apr 2023 06:02:32 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: c++ X-Bugzilla-Version: 11.3.0 X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: pinskia at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: see_also keywords short_desc Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D109480 Andrew Pinski changed: What |Removed |Added ---------------------------------------------------------------------------- See Also| |https://gcc.gnu.org/bugzill | |a/show_bug.cgi?id=3D41437 Keywords| |rejects-valid Summary|g++-12 and g++-11 failed to |[11/12/13 Regression] |compile the attached source |non-depedent access goes |file while g++-10 and clang |wrong in a template method |can. |sometimes --- Comment #2 from Andrew Pinski --- Most likely this was caused by r11-1350 . Reduced further: ``` template struct s { protected: bool g(); void f(); //template friend struct s; }; template void s::f() { s l; const bool b =3D l.g(); } ``` This means also s::f would be the only valid specialization here too.=