From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 056C63858C00; Sun, 18 Sep 2022 01:40:25 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 056C63858C00 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1663465225; bh=c4rg8qnB/KVHcNxrJXXuVmt/b/SibvdkhQ+wBScO0H0=; h=From:To:Subject:Date:In-Reply-To:References:From; b=EnCjtLbmaia9Dg98MdYqerkI81G3NVvUNY1WpRSt31tyueRQUvMgKhVcXYjM37h5P +ImSJbspadSdqZSxIqJRsFghMv2pza8LgSxmK54hWqDldI2H/ZSLxCxNq0ng5k2VKm XWaspFsA6BpwH+a9KysOwfkkgGMK4Vvqe/FbZrcM= From: "arsen at aarsen dot me" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/103626] _GLIBCXX_HOSTED should respect -ffreestanding Date: Sun, 18 Sep 2022 01:40:22 +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: 12.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: arsen at aarsen dot me 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=3D103626 --- Comment #4 from Arsen Arsenovi=C4=87 --- (In reply to Jonathan Wakely from comment #3) > I don't think we need to add the #error to every header. For a start, use= rs > never include the bits/* headers directly, and if they do, it's their > problem. So we only need to mark the standard headers as hosted-only. And= if > we add it to , that already covers a large number of them, because > they include that. My thinking behind doing that was that it'd make includes transitively carr= y a requirement on hosted, so that if some header is meant to be freestanding, = but depends on a hosted header, that could be detected (and that could probably= be a testcase).=