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

Andrew Pinski <pinskia at gcc dot gnu.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
     Ever confirmed|0                           |1
           Keywords|                            |ice-on-invalid-code
   Last reconfirmed|                            |2024-07-05
             Status|UNCONFIRMED                 |NEW

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
Note if you change C to be not an empty struct; e.g. add `int t;` as a field.
we get an ICE now:
```
<source>: In static member function 'static void C::g()':
<source>:7:12: internal compiler error: in gimplify_expr, at gimplify.cc:19084
    7 |        C::f();      //#1: gcc accepts but clang and msvc rejects
      |        ~~~~^~
0x26df0a5 diagnostic_context::diagnostic_impl(rich_location*,
diagnostic_metadata const*, int, char const*, __va_list_tag (*) [1],
diagnostic_t)
        ???:0
0x26ecc52 internal_error(char const*, ...)
        ???:0
0xa65f74 fancy_abort(char const*, int, char const*)
        ???:0
0x106d08f gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*),
int)
        ???:0
0x106ef9c gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*),
int)
        ???:0
0x107ca93 gimplify_arg(tree_node**, gimple**, unsigned int, bool)
        ???:0
0x106d370 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*),
int)
        ???:0
0x106d245 gimplify_expr(tree_node**, gimple**, gimple**, bool (*)(tree_node*),
int)
        ???:0
0x1080253 gimplify_body(tree_node*, bool)
        ???:0
0x1080699 gimplify_function_tree(tree_node*)
        ???:0
```

Confirmed.

Reply via email to