From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id A595F3858D3C; Wed, 21 Jun 2023 18:51:49 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org A595F3858D3C DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1687373509; bh=1kxgEUvZ6jxk8r9sg8RxGFcQGRrU3v1RZYW/ETtNk3o=; h=From:To:Subject:Date:In-Reply-To:References:From; b=Q/b9uigq9IoMKX6dadwtQcSL3sH46Zr3oVI4hUN1xcFYjRDm57PJuW5lgb4IqsTld BS4epO/hzjDDNE+ZFnEs9Mhst36HcFu6l62/Hnl1RX6xFEwyAhOfP8z2sZhR/nvxRq oWXSyHDGh3K3fDBV8KuH56J9F6Ce/3JDQY5RpShc= From: "mpolacek at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/109642] False Positive -Wdangling-reference with std::span-like classes Date: Wed, 21 Jun 2023 18:51: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: 13.1.0 X-Bugzilla-Keywords: diagnostic X-Bugzilla-Severity: normal X-Bugzilla-Who: mpolacek at gcc dot gnu.org 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=3D109642 --- Comment #9 from Marek Polacek --- My plan is to allow users to do #pragma GCC diagnostic push #pragma GCC diagnostic ignored "-Wdangling-reference" ... #pragma GCC diagnostic pop around the *class* itself to suppress the warning, not every use of the cla= ss. Sorry, Carlos and Barry, that I haven't gotten around to it yet.=