From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 914B8385829C; Thu, 7 Mar 2024 15:23:27 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 914B8385829C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1709825007; bh=3lJCs6CclV8awTtGtqL3rtiYuyaXA2cEqU+fg2OUwz8=; h=From:To:Subject:Date:In-Reply-To:References:From; b=KSKMTXCLnUagM3SVDF4LgnpvdcXEZZIUBuSNV0aP6r0icmm8SB7J98kDtsenKq1BT t3m8iYxjT/FRBc8azNdKIKn0k6XNobN9OU6XsfC2DoDTYdeeFoafUXo30Ob0F6njyN eHW6z0McBMM5R3xBf19emH4VZIOpJTSPYONqVKgU= From: "mpolacek at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/110323] [11/12/13/14 Regression] Code for explicit instantiation of template method of template class not generated Date: Thu, 07 Mar 2024 15:23:27 +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.1.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: mpolacek at gcc dot gnu.org X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: mpolacek at gcc dot gnu.org X-Bugzilla-Target-Milestone: 11.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 List-Id: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D110323 --- Comment #6 from Marek Polacek --- Extended test. I think all 4 should be emitted. ``` // PR c++/110323 template struct conditional { using type =3D T; }; template struct conditional { using type =3D F; }; constexpr int VAL =3D 1; static constexpr int getval () { return 1; } template constexpr int TVAL =3D 1; static struct S { constexpr operator bool() { return true; } } s; struct foo { template void bar(typename conditional::type arg) { } template void baz(typename conditional::type arg= ) { } template void qux(typename conditional, int, float>::type arg= ) { } template void lox(typename conditional::type arg) { } }; template void foo::bar<1>(int arg); template void foo::baz<1>(int arg); template void foo::qux<1>(int arg); template void foo::lox<1>(int arg); ```=