Re: gcc warn C++ implicit enum conversion

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 1 Jul 2019 at 23:40, Jonny Grant wrote:
>
> Hi
> Is there any way to warn on enum conversion to int?

I don't think so.

I'd just use 'enum class' so the conversion is forbidden, and insert
explicit casts where you want the conversion to compile.



[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux