From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 010763858C39; Tue, 13 Feb 2024 01:17:09 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 010763858C39 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1707787030; bh=Ei9mD/nQ5lT+9B8Wd6P3alEQ/E/1TwkNE7I54MlMRB8=; h=From:To:Subject:Date:In-Reply-To:References:From; b=MUK1qzfs706KejYnTTadlHs8JfKTRIZ2h3UDEu0DUao+Sda7ZkcE2w7MKHrsKnzvO QmGAwAkvDMku/OTgzvbxJWTXCOAHUeXHfJKbL8KWCgmu7pJjNXTLHVGFrG5xljQ6jA x1hq2RXaQIkzjmo2idDTpGKrhoXJo7mELP0XbUak= From: "harald at gigawatt dot nl" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/113760] [DR1693] gcc rejects valid empty-declaration in pedantic mode Date: Tue, 13 Feb 2024 01:17:03 +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: unknown X-Bugzilla-Keywords: rejects-valid X-Bugzilla-Severity: normal X-Bugzilla-Who: harald at gigawatt dot nl X-Bugzilla-Status: ASSIGNED X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: mpolacek 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=3D113760 --- Comment #13 from Harald van Dijk --- (In reply to Marek Polacek from comment #12) > Thank for your comment. In the end I went with >=20 > -std=3Dc++03 -pedantic-errors -Wextra-semi -> warnings > -std=3Dc++03 -pedantic -Wextra-semi -> warnings (not pedwarn) >=20 > based on the principle that a more specific option overrides a more gener= al > option. This is also what clang++ does. Granted, -Wvla in C doesn't beh= ave > like that... That also makes sense. The more specific option overriding a more general option is also the reasoning why I expect no error with -pedantic-errors -Wno-error=3Dextra-semi.=