Constified and shuffled by Floessie #4999

I added the missing "(Unchanged)" mode for Batch Edit,
which is currently broken #5002.
This commit is contained in:
Morgan Hardwood
2018-11-20 12:47:25 +01:00
parent 452dec763c
commit 7e70412090
3 changed files with 336 additions and 330 deletions

View File

@@ -56,6 +56,13 @@ constexpr const T& min(const T& a, const T& b)
return b < a ? b : a;
}
template<>
constexpr const float& min(const float& a, const float& b)
{
// For consistency reasons we return b instead of a if a == b or a == NaN
return a < b ? a : b;
}
template<typename T, typename... ARGS>
constexpr const T& min(const T& a, const T& b, const ARGS&... args)
{
@@ -74,6 +81,13 @@ constexpr const T& max(const T& a, const T& b)
return a < b ? b : a;
}
template<>
constexpr const float& max(const float& a, const float& b)
{
// For consistency reasons we return b instead of a if a == b or a == NaN
return b < a ? a : b;
}
template<typename T, typename... ARGS>
constexpr const T& max(const T& a, const T& b, const ARGS&... args)
{