From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id AEC36385DC16; Thu, 25 Aug 2022 17:13:32 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org AEC36385DC16 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1661447612; bh=ivyEpxIb1tjCqFB8P8zUrWiAJ/3MnXR7Znxgl6NNz9Q=; h=From:To:Subject:Date:In-Reply-To:References:From; b=Tx8zVGcg/e7WnTgo8K4FYT95ZrQbFcXb0zzNelPv3X0Z1Q4STd/7uxkXlNJJjnYI7 vZgRouB53dz/lwJBd8RFYIvoDDpPACRMWbG2A/q4z0iZO7MnFjOcGxgOTEeAIH5NiE F77p2mT7fiHxeBkPoSis9Zyqe+lshMPavMj/MCFc= From: "pinskia at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug analyzer/106741] suspicious %qE related warning when building gcc Date: Thu, 25 Aug 2022 17:13:32 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: analyzer X-Bugzilla-Version: 12.2.0 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: pinskia at gcc dot gnu.org X-Bugzilla-Status: WAITING X-Bugzilla-Resolution: X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: dmalcolm 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=3D106741 --- Comment #2 from Andrew Pinski --- /* If we haven't already defined a front-end-specific diagnostics style, use the generic one. */ #ifdef GCC_DIAG_STYLE #define GCC_PPDIAG_STYLE GCC_DIAG_STYLE #else #define GCC_PPDIAG_STYLE __gcc_diag__ #endif /* This header may be included before diagnostics-core.h, hence the duplica= te definitions to allow for GCC-specific formats. */ #if GCC_VERSION >=3D 3005 #define ATTRIBUTE_GCC_PPDIAG(m, n) __attribute__ ((__format__ (GCC_PPDIAG_STYLE, m ,n))) ATTRIBUTE_NONNULL(m) #else #define ATTRIBUTE_GCC_PPDIAG(m, n) ATTRIBUTE_NONNULL(m) #endif extern void pp_printf (pretty_printer *, const char *, ...) ATTRIBUTE_GCC_PPDIAG(2,3); %qE support was added for GCC 8, with r8-499-631238ac3f50 . So if you are compiling with GCC 7 (or before), the first stage will warn a= bout an unknown conversion type character =E2=80=98E=E2=80=99 but the 2nd and 3r= d stages won't.=