aboutsummaryrefslogtreecommitdiff
path: root/src/util/algorithm.hpp
diff options
context:
space:
mode:
authorHampusM <hampus@hampusmat.com>2022-06-12 13:44:58 +0200
committerHampusM <hampus@hampusmat.com>2022-06-13 17:57:01 +0200
commit927e065f9829045247be7c0b3296408b6f577c1f (patch)
tree7da3d9cd5aa4070414a8708a582f6c3ab3e1e708 /src/util/algorithm.hpp
parenteb66598c326862fd9dfc1899be4eac93f81a8023 (diff)
feat: add reading RLE files
Diffstat (limited to 'src/util/algorithm.hpp')
-rw-r--r--src/util/algorithm.hpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/util/algorithm.hpp b/src/util/algorithm.hpp
index e3d8b6f..60c68e2 100644
--- a/src/util/algorithm.hpp
+++ b/src/util/algorithm.hpp
@@ -9,6 +9,13 @@ requires Container<ContainerType>
constexpr auto container_find(const ContainerType &container, const Value &value) noexcept
-> typename ContainerType::const_iterator;
+template <typename ContainerType, typename Predicate>
+requires Container<ContainerType> &&
+ std::predicate<Predicate, typename ContainerType::value_type>
+constexpr auto
+container_find(const ContainerType &container, Predicate predicate) noexcept ->
+ typename ContainerType::const_iterator;
+
template <typename ContainerType, typename Value>
requires Container<ContainerType>
constexpr auto container_has(const ContainerType &container, const Value &value) noexcept