diff --git a/src/openrct2/core/Numerics.hpp b/src/openrct2/core/Numerics.hpp index 8152347204..4de93adfd8 100644 --- a/src/openrct2/core/Numerics.hpp +++ b/src/openrct2/core/Numerics.hpp @@ -23,7 +23,7 @@ namespace Numerics * @param shift positions to shift * @return rotated value */ - template constexpr _UIntType rol(_UIntType x, size_t shift) + template static constexpr _UIntType rol(_UIntType x, size_t shift) { static_assert(std::is_unsigned<_UIntType>::value, "result_type must be an unsigned integral type"); using limits = typename std::numeric_limits<_UIntType>; @@ -37,7 +37,7 @@ namespace Numerics * @param shift positions to shift * @return rotated value */ - template constexpr _UIntType ror(_UIntType x, size_t shift) + template static constexpr _UIntType ror(_UIntType x, size_t shift) { static_assert(std::is_unsigned<_UIntType>::value, "result_type must be an unsigned integral type"); using limits = std::numeric_limits<_UIntType>; diff --git a/src/openrct2/world/Location.hpp b/src/openrct2/world/Location.hpp index b9097a12b4..b8e4d3271e 100644 --- a/src/openrct2/world/Location.hpp +++ b/src/openrct2/world/Location.hpp @@ -164,7 +164,7 @@ typedef uint8_t Direction; * Given a direction, return the direction that points the other way, * on the same axis. */ -constexpr Direction direction_reverse(Direction dir) +[[maybe_unused]] static constexpr Direction direction_reverse(Direction dir) { return dir ^ 2; }