From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 63A7E3858C62; Thu, 1 Sep 2022 22:00:19 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 63A7E3858C62 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1662069619; bh=QLeC2raXF+Js5Y2M7dkCzBNWOJ249FAbzDFOewKRWKI=; h=From:To:Subject:Date:In-Reply-To:References:From; b=sllW13qzOc5T7dug5e3BDx+hCwYz/sdghlRW0wrgl/5auNhpwTxxykjk/vI5xjj+X jJE9vnv0cRV2sVA0CENqIzvYVaTs+8l3cmwUp0YkGyJMoNtbemXF4tsSDpi+whPJTh xOVwqz0Qr13+w0o/sR20yB4gGCTtPBhKgaYib3/E= From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/71579] type_traits miss checks for type completeness in some traits Date: Thu, 01 Sep 2022 22:00:19 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 6.1.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: redi 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: 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=3D71579 --- Comment #21 from Jonathan Wakely --- The precondition for has_virtual_destructor is: "If T is a non-union class type, T shall be a complete type." Our type trait and the __has_virtual_destructor built-in both seem to get this wrong, rejecting Incomplete[2], which is not a class type, and so doesn't need to be complete (or maybe the precondition is wrong and there's a library defect?)=