diff options
author | Dominick Allen <djallen@librehumanitas.org> | 2025-04-02 05:25:26 -0500 |
---|---|---|
committer | Dominick Allen <djallen@librehumanitas.org> | 2025-04-02 05:25:26 -0500 |
commit | 1d2ad781398d2a8743899eb54153998ca03ac090 (patch) | |
tree | c935ffe2880b7101d2d9162a76c8bed5be931ebb /include/fud_algorithm.hpp | |
parent | 8b0bc70db73b48d833a3b5791e55921768cf6932 (diff) |
More work on hash maps.
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: |