public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug c++/111286] New: ICE on functional cast to const array reference
@ 2023-09-04 19:12 leni536 at gmail dot com
  2023-09-04 19:18 ` [Bug c++/111286] [12/13/14 Regression] ICE on functional cast empty brace-init-list " pinskia at gcc dot gnu.org
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: leni536 at gmail dot com @ 2023-09-04 19:12 UTC (permalink / raw)
  To: gcc-bugs

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

            Bug ID: 111286
           Summary: ICE on functional cast to const array reference
           Product: gcc
           Version: 13.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c++
          Assignee: unassigned at gcc dot gnu.org
          Reporter: leni536 at gmail dot com
  Target Milestone: ---

With g++ 13.2.0
with flags: -std=c++20

The following code:

```
struct A {
    A() noexcept {}
};

void foo() {
    using T = const A (&)[1];
    T{};
}
```

Produces the following compiler output:

<source>: In function 'void foo()':
<source>:7:7: internal compiler error: in cp_build_addr_expr_1, at
cp/typeck.cc:7147
    7 |     T{};
      |       ^
0x1ce7bde internal_error(char const*, ...)
        ???:0
0x7290fc fancy_abort(char const*, int, char const*)
        ???:0
0x74b040 perform_implicit_conversion_flags(tree_node*, tree_node*, int, int)
        ???:0
0x8e9510 finish_compound_literal(tree_node*, tree_node*, int, fcl_t)
        ???:0
0x89fd5b c_parse_file()
        ???:0
0x98c5d9 c_common_parse_file()
        ???:0


https://godbolt.org/z/MaWTTv4Y7

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-02-05 22:26 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-09-04 19:12 [Bug c++/111286] New: ICE on functional cast to const array reference leni536 at gmail dot com
2023-09-04 19:18 ` [Bug c++/111286] [12/13/14 Regression] ICE on functional cast empty brace-init-list " pinskia at gcc dot gnu.org
2023-09-05 14:19 ` mpolacek at gcc dot gnu.org
2023-09-13  7:01 ` gayathri.gottumukkala.27 at gmail dot com
2024-02-05 18:40 ` jason at gcc dot gnu.org
2024-02-05 21:33 ` cvs-commit at gcc dot gnu.org
2024-02-05 22:25 ` cvs-commit at gcc dot gnu.org
2024-02-05 22:25 ` cvs-commit at gcc dot gnu.org
2024-02-05 22:26 ` jason at gcc dot gnu.org

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).