diff options
Diffstat (limited to 'include/fud_algorithm.hpp')
-rw-r--r-- | include/fud_algorithm.hpp | 27 |
1 files changed, 1 insertions, 26 deletions
diff --git a/include/fud_algorithm.hpp b/include/fud_algorithm.hpp index 82e98cb..ef55d21 100644 --- a/include/fud_algorithm.hpp +++ b/include/fud_algorithm.hpp @@ -18,6 +18,7 @@ #ifndef FUD_ALGORITHM_HPP #define FUD_ALGORITHM_HPP +#include "fud_algorithm_no_dep.hpp" // IWYU pragma: export #include "fud_option.hpp" #include "fud_span.hpp" @@ -26,32 +27,6 @@ namespace fud { -template<typename T> -concept LessThanComparable = - requires(T lhs, T rhs) { - { lhs < rhs } -> std::convertible_to<bool>; -}; - -template <LessThanComparable T> -inline const T& min(const T& lhs, const T& rhs) { - if (lhs < rhs) { - // NOLINTNEXTLINE(bugprone-return-const-ref-from-parameter) - return lhs; - } - // NOLINTNEXTLINE(bugprone-return-const-ref-from-parameter) - return rhs; -} - -template <LessThanComparable T> -inline const T& max(const T& lhs, const T& rhs) { - if (lhs < rhs) { - // NOLINTNEXTLINE(bugprone-return-const-ref-from-parameter) - return rhs; - } - // NOLINTNEXTLINE(bugprone-return-const-ref-from-parameter) - return lhs; -} - template <std::integral T> class Iota { public: |