[cfe-dev] Unsound assumptions about exhaustiveness of enum switch cases?
Joerg Sonnenberger via cfe-dev
cfe-dev at lists.llvm.org
Sat Sep 12 09:18:22 PDT 2015
On Fri, Sep 11, 2015 at 01:46:31PM +0200, Stephan Bergmann via cfe-dev wrote:
> Is this analysis deliberately unsound, on the assumption that objects of
> enumeration type take only enumerator values? If yes, is it deliberate to
> do so for both scoped and unscoped enumerations?
If you want to be explicitly about the switch not being covering, cast
the variable to the underlaying integer type.
More information about the cfe-dev