public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "mpolacek at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug c++/99980] New: Delayed parsing of noexcept doesn't work in member function template Date: Thu, 08 Apr 2021 19:11:58 +0000 [thread overview] Message-ID: <bug-99980-4@http.gcc.gnu.org/bugzilla/> (raw) https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99980 Bug ID: 99980 Summary: Delayed parsing of noexcept doesn't work in member function template Product: gcc Version: 11.0 Status: UNCONFIRMED Severity: normal Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: mpolacek at gcc dot gnu.org Target Milestone: --- We should accept this: struct S { template<typename T> void f(T) noexcept(B); static constexpr bool B = true; }; but we don't; we need something like --- a/gcc/cp/parser.c +++ b/gcc/cp/parser.c @@ -30526,7 +30526,8 @@ cp_parser_single_declaration (cp_parser* parser, || decl_specifiers.type != error_mark_node)) { decl = cp_parser_init_declarator (parser, - CP_PARSER_FLAGS_TYPENAME_OPTIONAL, + CP_PARSER_FLAGS_TYPENAME_OPTIONAL + | CP_PARSER_FLAGS_DELAY_NOEXCEPT, &decl_specifiers, checks, /*function_definition_allowed_p=*/true, (but not when friend_p). Found while looking into https://gcc.gnu.org/bugzilla/show_bug.cgi?id=99806#c3.
next reply other threads:[~2021-04-08 19:11 UTC|newest] Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top 2021-04-08 19:11 mpolacek at gcc dot gnu.org [this message] 2021-04-08 19:12 ` [Bug c++/99980] " mpolacek at gcc dot gnu.org 2021-12-16 22:40 ` cvs-commit at gcc dot gnu.org 2021-12-16 22:46 ` mpolacek at gcc dot gnu.org 2023-12-27 19:51 ` pinskia 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-99980-4@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: linkBe 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).