| ▲ | poppadom1982 3 hours ago | ||||||||||||||||||||||
I'm not sure what you're getting at but const bool z = (const bool)((int8_t)2); Is perfectly valid C++. | |||||||||||||||||||||||
| ▲ | debugnik 3 hours ago | parent [-] | ||||||||||||||||||||||
That's a conversion, not the same. The naive equivalent to transmute would be
But reinterpret_cast isn't valid in a constexpr scope. | |||||||||||||||||||||||
| |||||||||||||||||||||||