From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 7A0083858D28; Fri, 11 Aug 2023 19:39:53 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 7A0083858D28 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gcc.gnu.org; s=default; t=1691782793; bh=nZwD9+36vVwoPxNLoHtbIByyhV6S++mymX3Xi1BqKLI=; h=From:To:Subject:Date:In-Reply-To:References:From; b=KOu0dMkZ+DjfHjUeIBI0Bw5qYIAEm133ZaRqiaQVLVwVf+Kgx8MNR6BU7cH7m0RQV 2kwIGOKzdPA1QfgZMtwsQ9aTBnoyMUoJ8/upxjjDl0UJjsHIZiolJ6itNzWy8H0YZa o1z1uW3PtkJYPTa52G2wr+tEiYDBvqZp/w4zQbUM= From: "mpolacek at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/107687] [C++23] P2564 - consteval needs to propagate up Date: Fri, 11 Aug 2023 19:39:52 +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: 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=3D107687 --- Comment #2 from Marek Polacek --- I don't understand why clang++ doesn't error here: -- consteval int id(int i) { return i; } template constexpr int f (T t) { auto p =3D id; // immediate-escalating expr return t; } auto q =3D &f; // error? -- I though naming 'id' should promote f to consteval and therefore you c= an't take its address.=