Fix compilation

This commit is contained in:
Jérôme Leclercq 2021-12-01 20:35:18 +01:00
parent 61779d1cad
commit 84bc04cee7
1 changed files with 2 additions and 1 deletions

View File

@ -13,6 +13,7 @@
#include <Nazara/Core/Stream.hpp>
#include <cassert>
#include <climits>
#include <cmath>
#include <limits>
#include <utility>
#include <Nazara/Core/Debug.hpp>
@ -327,7 +328,7 @@ namespace Nz
template<typename To, typename From, std::enable_if_t<std::is_integral_v<To> && std::is_floating_point_v<From>, int>>
To SafeCast(From value)
{
assert(floor(value) == value);
assert(std::floor(value) == value);
assert(value <= static_cast<From>(std::numeric_limits<To>::max()));
assert(value >= static_cast<From>(std::numeric_limits<To>::lowest()));