Data interchange, editor suite, and runtime re-implementations for games by Retro Studios
Go to file
Lioncash 06c436b68d hecl/FourCC: Eliminate undefined behavior within FourCC interface
Type punning like this isn't actually well-defined behavior. Only
casting to char/unsigned char is well defined. This presents a problem
when using FourCC instances in constexpr contexts, given constexpr
contexts are forbidden from having undefined behavior in them.

Because of that, any attempt to use the const char* constructor within a
constexpr context would always result in a compilation error.
2019-08-15 06:48:31 -04:00
hecl hecl/FourCC: Eliminate undefined behavior within FourCC interface 2019-08-15 06:48:31 -04:00