Selaa lähdekoodia

Support pointers lib using pointers namespace

Sam Jaffe 5 vuotta sitten
vanhempi
commit
ee7a79e15f
2 muutettua tiedostoa jossa 4 lisäystä ja 2 poistoa
  1. 3 1
      include/trie/trie.hpp
  2. 1 1
      include/trie/trie.tpp

+ 3 - 1
include/trie/trie.hpp

@@ -46,7 +46,9 @@ public:
   using key_type = K;
   using mapped_type = V;
   using key_compare = Compare;
-  using map_type = std::map<K, const_propogating_ptr<value_ptr<trie>>, Compare>;
+  using map_type =
+      std::map<K, pointers::const_propogating_ptr<pointers::value_ptr<trie>>,
+               Compare>;
 
   using local_iterator = typename map_type::iterator;
   using local_const_iterator = typename map_type::const_iterator;

+ 1 - 1
include/trie/trie.tpp

@@ -63,7 +63,7 @@ void trie<K, V, C>::insert_impl(impl_iterator & out, bool & create,
   auto it = impl_.lower_bound(key);
   if (it == impl_.end() || key_compare()(key, it->first)) {
     create = true;
-    it = impl_.emplace_hint(it, key, make_value<trie>());
+    it = impl_.emplace_hint(it, key, pointers::make_value<trie>());
   }
   out.push({it, impl_.end()});
 }