lesept:
Je croyais que switch ne fonctionnait qu'avec une variable de type int ou char. Non ?
Non la spécification dit
any expression of integral or enumeration type, or of a class type contextually implicitly convertible to an integral or enumeration type,
donc un byte va très bien aussi