1
0
mirror of https://github.com/OpenRCT2/OpenRCT2 synced 2026-01-21 22:13:07 +01:00

Mark functions as static

This commit is contained in:
Michał Janiszewski
2019-02-09 22:56:50 +01:00
parent 379fd42dc4
commit 838289abce
2 changed files with 3 additions and 3 deletions

View File

@@ -23,7 +23,7 @@ namespace Numerics
* @param shift positions to shift
* @return rotated value
*/
template<typename _UIntType> constexpr _UIntType rol(_UIntType x, size_t shift)
template<typename _UIntType> 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<typename _UIntType> constexpr _UIntType ror(_UIntType x, size_t shift)
template<typename _UIntType> 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>;

View File

@@ -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;
}