diff options
author | Boris Kolpackov <boris@codesynthesis.com> | 2018-01-19 09:06:39 +0200 |
---|---|---|
committer | Boris Kolpackov <boris@codesynthesis.com> | 2018-01-19 09:06:39 +0200 |
commit | 3053f55528dbecb08ddb55fa94546a98af06e3e1 (patch) | |
tree | 6f9dc9fb9fe6c5593f1304f884d5c49c89bcad0b /libbutl/path-map.mxx | |
parent | 89bc63fb386f0e4d6e2b21c0d806da1e8de0a34d (diff) |
Reimplement prefix_map::find_sup() to iterate over key, not entries
Diffstat (limited to 'libbutl/path-map.mxx')
-rw-r--r-- | libbutl/path-map.mxx | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/libbutl/path-map.mxx b/libbutl/path-map.mxx index 2697a48..95fd54b 100644 --- a/libbutl/path-map.mxx +++ b/libbutl/path-map.mxx @@ -79,6 +79,16 @@ LIBBUTL_MODEXPORT namespace butl root (ks) ? string_type () : ks); } + bool + prefix (key_type& k) const + { + if (k.empty ()) + return false; + + k.make_directory (); + return true; + } + protected: bool prefix (const string_type& p, const string_type& k) const |