public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "hewillk at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/105541] ICE: Segmentation fault when template lambda in requires-clause
Date: Tue, 10 May 2022 02:26:35 +0000 [thread overview]
Message-ID: <bug-105541-4-kNfbZjOHKT@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-105541-4@http.gcc.gnu.org/bugzilla/>
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105541
--- Comment #1 from 康桓瑋 <hewillk at gmail dot com> ---
(In reply to 康桓瑋 from comment #0)
> template<class>
> constexpr bool is_hello = false;
>
> template <typename T>
> requires (!is_hello<T>)
> class Hello;
>
> template <typename T>
> requires (!is_hello<T>)
> class Hello {};
>
> static_assert(requires { []<Hello<int>>{}; });
>
> https://godbolt.org/z/rTM5chYf3
>
> GCC-11 rejects this valid syntax, and GCC-12 emits ICE.
Sorry, GCC-11 compiles fine, this is a 12-regression.
next prev parent reply other threads:[~2022-05-10 2:26 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-10 2:24 [Bug c++/105541] New: " hewillk at gmail dot com
2022-05-10 2:26 ` hewillk at gmail dot com [this message]
2022-05-10 7:50 ` [Bug c++/105541] [12/13 Regression] " rguenth at gcc dot gnu.org
2022-05-10 13:46 ` mpolacek at gcc dot gnu.org
2022-05-10 22:18 ` jason at gcc dot gnu.org
2022-05-10 22:22 ` jason at gcc dot gnu.org
2022-05-11 19:30 ` cvs-commit at gcc dot gnu.org
2022-07-01 14:56 ` [Bug c++/105541] [12 " cvs-commit at gcc dot gnu.org
2022-07-01 14:57 ` jason at gcc dot gnu.org
2023-05-25 13:10 ` ppalka at gcc dot gnu.org
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=bug-105541-4-kNfbZjOHKT@http.gcc.gnu.org/bugzilla/ \
--to=gcc-bugzilla@gcc.gnu.org \
--cc=gcc-bugs@gcc.gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).