3 ms·
Well, if we were starting from scratch {u,}int8_t should definitely not be character type; instead we would have byte_t (plus an explicitly sized variant, octec
by gpderetta 3y ago
Well, if we were starting from scratch {u,}int8_t should definitely not be character type; instead we would have byte_t (plus an explicitly sized variant, octect_t?) as the general universally aliasable byte type, and all of these would be guaranteed to be distinct types.
But today, uint8_t is in practice always a char type. You can static_assert if you want to be completely sure. Or just use std::byte.