public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "eric.niebler at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug c++/110552] New: ICE on valid code in maybe_instantiate_noexcept
Date: Tue, 04 Jul 2023 18:07:20 +0000	[thread overview]
Message-ID: <bug-110552-4@http.gcc.gnu.org/bugzilla/> (raw)

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=110552

            Bug ID: 110552
           Summary: ICE on valid code in maybe_instantiate_noexcept
           Product: gcc
           Version: 14.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: eric.niebler at gmail dot com
  Target Milestone: ---

Created attachment 55469
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=55469&action=edit
self-contained source file

Compile the attached source with -std=c++20. Result:

/home/eniebler/hello_world.cpp: In substitution of ‘template<class
_EnvProvider>  requires  tag_invocable<stdexec::__env::get_env_t, const
_EnvProvider&> constexpr
stdexec::__tag_invoke::tag_invoke_result_t<stdexec::__env::get_env_t, const
_EnvProvider&> stdexec::__env::get_env_t::operator()(const _EnvProvider&) const
[with _EnvProvider = stdexec::__basic_sender<<lambda(_Data, _Children
...)>::<lambda(_Cvref, _Fun&&)> >]’:
/home/eniebler/hello_world.cpp:2221:16:   required from here
/home/eniebler/hello_world.cpp:1465:59: internal compiler error: in
maybe_instantiate_noexcept, at cp/pt.cc:26753
 1465 |       requires(_Tag __tag, _Args&&... __args) { tag_invoke((_Tag&&)
__tag, (_Args&&) __args...); };
      |                                                
~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
0xace10a maybe_instantiate_noexcept(tree_node*, int)
        ../../gcc/cp/pt.cc:26753
0x96272f mark_used(tree_node*, int)
        ../../gcc/cp/decl2.cc:5720
0x864a35 build_over_call
        ../../gcc/cp/call.cc:10394
0x867e0b build_new_function_call(tree_node*, vec<tree_node*, va_gc,
vl_embed>**, int)
        ../../gcc/cp/call.cc:5038
0xb304ff finish_call_expr(tree_node*, vec<tree_node*, va_gc, vl_embed>**, bool,
bool, int)
        ../../gcc/cp/semantics.cc:2924
0xacc4e5 tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*)
        ../../gcc/cp/pt.cc:21338
0xabb964 tsubst_expr(tree_node*, tree_node*, int, tree_node*)
        ../../gcc/cp/pt.cc:19888
0x8c3193 tsubst_valid_expression_requirement
        ../../gcc/cp/constraint.cc:2002
0x8cc3c0 tsubst_simple_requirement
        ../../gcc/cp/constraint.cc:2036
0x8cc3c0 tsubst_requirement
        ../../gcc/cp/constraint.cc:2233
0x8cc3c0 tsubst_requires_expr
        ../../gcc/cp/constraint.cc:2363
0x8cc8aa tsubst_requires_expr(tree_node*, tree_node*, int, tree_node*)
        ../../gcc/cp/constraint.cc:2382
0xac96c7 tsubst_copy_and_build(tree_node*, tree_node*, int, tree_node*)
        ../../gcc/cp/pt.cc:21749
0xabb964 tsubst_expr(tree_node*, tree_node*, int, tree_node*)
        ../../gcc/cp/pt.cc:19888
0x8cde63 satisfy_atom
        ../../gcc/cp/constraint.cc:3041
0x8cde63 satisfy_constraint_r
        ../../gcc/cp/constraint.cc:3106
0x8ce723 satisfy_normalized_constraints
        ../../gcc/cp/constraint.cc:3131
0x8caefd satisfy_declaration_constraints
        ../../gcc/cp/constraint.cc:3352
0x8caefd constraint_satisfaction_value
        ../../gcc/cp/constraint.cc:3373
0x8ce78f constraints_satisfied_p(tree_node*, tree_node*)
        ../../gcc/cp/constraint.cc:3410
Please submit a full bug report, with preprocessed source (by using
-freport-bug).
Please include the complete backtrace with any bug report.
See <https://gcc.gnu.org/bugs/> for instructions.


See https://godbolt.org/z/1511TYvch for a demo of the bug on compiler explorer.

             reply	other threads:[~2023-07-04 18:07 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-07-04 18:07 eric.niebler at gmail dot com [this message]
2023-07-04 18:49 ` [Bug c++/110552] " pinskia at gcc dot gnu.org
2023-07-04 21:13 ` pinskia at gcc dot gnu.org
2023-07-04 21:28 ` pinskia at gcc dot gnu.org
2023-07-04 21:30 ` pinskia at gcc dot gnu.org
2023-07-04 21:30 ` pinskia at gcc dot gnu.org
2023-07-04 21:36 ` pinskia at gcc dot gnu.org
2024-04-13  8:25 ` 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-110552-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: 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).