diff options
author | Neil <nyamatongwe@gmail.com> | 2018-01-28 08:57:56 +1100 |
---|---|---|
committer | Neil <nyamatongwe@gmail.com> | 2018-01-28 08:57:56 +1100 |
commit | 6141b5164e83cf1122027decd88829e735ba707d (patch) | |
tree | 06d935d1388453c4068996074c82bb2b65ab0dae /src/Position.h | |
parent | 9d748e03134e5c15dd8cb9e8887b80dca0312b09 (diff) | |
download | scintilla-mirror-6141b5164e83cf1122027decd88829e735ba707d.tar.gz |
Replace Sci::clamp with C++ standard std::clamp function.
std::clamp is from C++17.
Diffstat (limited to 'src/Position.h')
-rw-r--r-- | src/Position.h | 9 |
1 files changed, 0 insertions, 9 deletions
diff --git a/src/Position.h b/src/Position.h index 166fc24da..a8fbfb494 100644 --- a/src/Position.h +++ b/src/Position.h @@ -21,15 +21,6 @@ typedef int Line; const Position invalidPosition = -1; -template <typename T> -inline constexpr T clamp(T val, T minVal, T maxVal) { - if (val > maxVal) - val = maxVal; - if (val < minVal) - val = minVal; - return val; -} - } #endif |