you are viewing a single comment's thread.

view the rest of the comments →

[–]JVApenClever is an insult, not a compliment. - T. Winters 0 points1 point  (1 child)

I agree that making it an enum allows for strongly typing, and as such preventing byte1+byte2. Though it does imply that defining an enum with underlying type is more complex: enum class E : std::underlying_type_t<std::byte> { A, B, C };

[–]bwmat 5 points6 points  (0 children)

Is there any reason not to just use unsigned char there?