diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2021-03-19 15:26:28 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2021-03-19 15:26:28 +0200 |
commit | 5ecdb9a3b5cb85418f69126226b2636caed2e4da (patch) | |
tree | df53881ecdb8c9efd1480097756a20ec262b1300 /libbutl/prefix-map.mxx | |
parent | e283b08481cfec9aa55b3ddbf369d632c7aa7b0f (diff) |
Add prefix_map::find_sup_if()
Diffstat (limited to 'libbutl/prefix-map.mxx')
-rw-r--r-- | libbutl/prefix-map.mxx | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/libbutl/prefix-map.mxx b/libbutl/prefix-map.mxx index 75931da..634b8da 100644 --- a/libbutl/prefix-map.mxx +++ b/libbutl/prefix-map.mxx @@ -149,6 +149,18 @@ LIBBUTL_MODEXPORT namespace butl const_iterator find_sup (const key_type&) const; + + + // As above but additionally evaluate a predicate on each matching entry + // returning the one for which it returns true. + // + template <typename P> + iterator + find_sup_if (const key_type&, P); + + template <typename P> + const_iterator + find_sup_if (const key_type&, P) const; }; template <typename M, typename prefix_map_common<M>::delimiter_type D> |