If I have an C++ enum:
enum Foo { Bar, Baz, Bork, };
How do I tell the compiler to use a uint16_t to actually store the
uint16_t
With c++11 you now have enum class, that allows you to set underlying type explicitly:
c++11
enum class Foo: uint16_t { Bar, Baz, Bork, };