From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 3BA323893669; Mon, 14 Dec 2020 20:56:48 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 3BA323893669 From: "ppalka at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/98216] [C++20] std::array template parameter error with negative values Date: Mon, 14 Dec 2020 20:56:48 +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.0 X-Bugzilla-Keywords: wrong-code X-Bugzilla-Severity: normal X-Bugzilla-Who: ppalka at gcc dot gnu.org X-Bugzilla-Status: NEW 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: cc 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: Mon, 14 Dec 2020 20:56:48 -0000 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D98216 Patrick Palka changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |ppalka at gcc dot gnu.org --- Comment #5 from Patrick Palka --- Related testcase which may or may not be caused by the same underlying bug: $ cat testcase.C template void foo() {} template void foo<-1.0>(); template void foo<-2.0>(); $ g++ -std=3Dc++20 testcase.C testcase.C:3:26: error: Two symbols with same comdat_group are not linked by the same_comdat_group list. 3 | template void foo<-2.0>();=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20 | ^=20=20 _Z3fooILdffffffff00000000EEvv/1 (void foo() [with double s =3D -2.0e+0]) @0x7fdb12c4aee0=20=20=20=20=20=20=20=20=20 Type: function definition analyzed Visibility: force_output forced_by_abi no_reorder public weak comdat_group:_Z3fooILdffffffff00000000EEvv one_only previous sharing asm name: 0 References:=20 Referring:=20=20=20=20=20=20=20=20=20=20 Function flags: body Called by:=20 Calls:=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20 _Z3fooILdffffffff00000000EEvv/0 (void foo() [with double s =3D -1.0e+0]) @0x7fdb12c4add0 Type: function definition analyzed=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20=20= =20=20=20=20=20=20 Visibility: force_output forced_by_abi no_reorder public weak comdat_group:_Z3fooILdffffffff00000000EEvv one_only next sharing asm name: 1 References:=20 Referring:=20 Function flags: body Called by:=20 Calls:=20 testcase.C:3:26: internal compiler error: symtab_node::verify failed 0xbebe81 symtab_node::verify_symtab_nodes() /home/patrick/code/gcc/gcc/symtab.c:1406 0xc00586 symtab_node::checking_verify_symtab_nodes() /home/patrick/code/gcc/gcc/cgraph.h:675=20 0xc00586 symbol_table::compile() /home/patrick/code/gcc/gcc/cgraphunit.c:2277 0xc02f67 symbol_table::compile() /home/patrick/code/gcc/gcc/cgraphunit.c:2274 0xc02f67 symbol_table::finalize_compilation_unit() /home/patrick/code/gcc/gcc/cgraphunit.c:2542=