[Bug c++/112515] [14 regression] ICE when building Transmission in standard_conversion with {} and type depdent and enum class

pinskia at gcc dot gnu.org gcc-bugzilla@gcc.gnu.org
Mon Nov 13 18:16:20 GMT 2023


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

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

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|[14 regression] ICE when    |[14 regression] ICE when
                   |building Transmission in    |building Transmission in
                   |standard_conversion         |standard_conversion with {}
                   |                            |and type depdent and enum
                   |                            |class

--- Comment #3 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
(In reply to Andrew Pinski from comment #2)
> Reduced testcase:
> ```
> enum class Ordering { SMALLER = -1, EQUAL, LARGER };
> template <typename T>
> Ordering compare_vfunc(T t) {
>   return Ordering{compare(t)};
> }
> 
> ```

Note the following definition of Ordering also causes the ICE:
```
enum  Ordering : int { SMALLER = -1, EQUAL, LARGER };
```


More information about the Gcc-bugs mailing list