diff options
Diffstat (limited to 'include/common.hpp')
-rw-r--r-- | include/common.hpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/include/common.hpp b/include/common.hpp index 73b4928..e082a87 100644 --- a/include/common.hpp +++ b/include/common.hpp @@ -240,7 +240,7 @@ void UserError(std::string reason); namespace std { template<class T> constexpr const T& clamp(const T& v, const T& lo, const T& hi) { - return (v > hi) ? ((v > lo) ? v : lo) : hi; + return (v > hi) ? hi : ((v > lo) ? v : lo); } } |