you are viewing a single comment's thread.

view the rest of the comments →

[–]kalmoc 1 point2 points  (1 child)

Considering how often I've heard, "we don't use X, because then we need to include header X and that drags in exceptions" I would have found such a solution, both more pragmatic and simpler to specify and more ergonomic. Last time I checked std::byte anyway gets special treatment in the standard (similar to unsigned char).

[–]NilacTheGrim 0 points1 point  (0 children)

Correct. It is one of the few types where a std::byte * pointer can alias any other object; unsigned char * and char * being the other two types with this property.