diff --git a/deps/ox/src/ox/std/bitops.hpp b/deps/ox/src/ox/std/bitops.hpp index 8a2956af..2b9fd1db 100644 --- a/deps/ox/src/ox/std/bitops.hpp +++ b/deps/ox/src/ox/std/bitops.hpp @@ -17,7 +17,7 @@ inline constexpr T rotateLeft(T i, int shift) { } template -constexpr T onMask(int bits) { +constexpr T onMask(int bits = sizeof(T)) { T out = 0; for (auto i = 0; i < bits; i++) { out |= static_cast(1) << i; diff --git a/deps/ox/src/ox/std/types.hpp b/deps/ox/src/ox/std/types.hpp index 1bab5c16..44fb987d 100644 --- a/deps/ox/src/ox/std/types.hpp +++ b/deps/ox/src/ox/std/types.hpp @@ -51,6 +51,13 @@ typedef uint32_t uintptr_t; #endif +namespace ox { + +template +constexpr auto MaxValue = onMask(); + +} + namespace std {