[ox/std] Remove constexpr from ox::bit_cast

This commit is contained in:
Gary Talent 2020-01-31 23:53:55 -06:00
parent 54a78ff04e
commit dd008c3a08

View File

@ -15,8 +15,8 @@
namespace ox { namespace ox {
template<typename To, typename From> template<typename To, typename From>
constexpr typename enable_if<sizeof(To) == sizeof(From), To>::type bit_cast(From src) noexcept { typename enable_if<sizeof(To) == sizeof(From), To>::type bit_cast(From src) noexcept {
To dst; To dst = {};
memcpy(&dst, &src, sizeof(src)); memcpy(&dst, &src, sizeof(src));
return dst; return dst;
} }