aboutsummaryrefslogtreecommitdiff
path: root/src/common/math_util.h
diff options
context:
space:
mode:
authorLioncash <mathew1800@gmail.com>2018-04-19 23:01:50 -0400
committerLioncash <mathew1800@gmail.com>2018-04-20 10:14:13 -0400
commitfae2dd034462c5a6b086e46b3437ea6e2456d5eb (patch)
tree3a53e7b4786e4712874d63a2a1cecc6755475051 /src/common/math_util.h
parent17ad56c1dce85e71d5ab8a87efd7d43d87cacd92 (diff)
math_util: Remove the Clamp() function
C++17 adds clamp() to the standard library, so we can remove ours in favor of it.
Diffstat (limited to 'src/common/math_util.h')
-rw-r--r--src/common/math_util.h5
1 files changed, 0 insertions, 5 deletions
diff --git a/src/common/math_util.h b/src/common/math_util.h
index 45a1ed3670..c6a83c9539 100644
--- a/src/common/math_util.h
+++ b/src/common/math_util.h
@@ -17,11 +17,6 @@ inline bool IntervalsIntersect(unsigned start0, unsigned length0, unsigned start
return (std::max(start0, start1) < std::min(start0 + length0, start1 + length1));
}
-template <typename T>
-inline T Clamp(const T val, const T& min, const T& max) {
- return std::max(min, std::min(max, val));
-}
-
template <class T>
struct Rectangle {
T left;