From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 989F63857371; Sun, 15 May 2022 16:29:29 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 989F63857371 From: "cvs-commit at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/102651] [9/10/11/12 Regression] typeid(X**) instantiates X caused by r0-109856 Date: Sun, 15 May 2022 16:29:29 +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: 12.0 X-Bugzilla-Keywords: patch, rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: cvs-commit at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: jason at gcc dot gnu.org X-Bugzilla-Target-Milestone: 9.5 X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: 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 X-BeenThere: gcc-bugs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Gcc-bugs mailing list List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 May 2022 16:29:29 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D102651 --- Comment #4 from CVS Commits --- The releases/gcc-12 branch has been updated by Jason Merrill : https://gcc.gnu.org/g:5237059e04d105fe5441fa7434699eea9a34bf1b commit r12-8378-g5237059e04d105fe5441fa7434699eea9a34bf1b Author: Jason Merrill Date: Fri Apr 15 00:11:00 2022 -0400 c++: typeid and instantiation [PR102651] PR49387 was a problem with initially asking for a typeid for a class template specialization before it was complete, and later actually fill= ing in the descriptor when the class was complete, and thus disagreeing on = the form of the descriptor. I fixed that by forcing the class to be comple= te, but this testcase shows why that approach is problematic. So instead l= et's adjust the type of the descriptor later if needed. PR c++/102651 PR c++/49387 gcc/cp/ChangeLog: * rtti.cc (get_tinfo_decl_direct): Don't complete_type. (emit_tinfo_decl): Update tdesc type if needed. gcc/testsuite/ChangeLog: * g++.dg/rtti/typeid-complete1.C: New test.=