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

--- Comment #5 from uecker at gcc dot gnu.org ---

Right, included the wrong test... 

The conversion seems right, if we have a predefined type. For enums with fixed
underlying type we then have a constraint violation if the value does not fit.
This may have been the intention also here, but it is not entirely clear. I
made an -Woverflow warning for now, so it behaves similar to other
initialization of constants and a warning is all that is required here. If the
final value ends up the same, the types are compatible so this part is then
fine.

Reply via email to