summaryrefslogtreecommitdiff
path: root/autofeur_db/src
diff options
context:
space:
mode:
authorMatthieuCoder <matthieu@matthieu-dev.xyz>2023-01-22 14:08:20 +0400
committerMatthieuCoder <matthieu@matthieu-dev.xyz>2023-01-22 14:08:20 +0400
commit0a64a05da2c0edb0177a9b533e4174bc712d54b1 (patch)
tree41d0e08c1587f62f50d944c47dfebdcfbff7be95 /autofeur_db/src
parent9f798c57f8525fb3e83fa2427fbdb645ebdf65eb (diff)
change licence and add a 30% probability
Diffstat (limited to 'autofeur_db/src')
-rw-r--r--autofeur_db/src/trie.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/autofeur_db/src/trie.rs b/autofeur_db/src/trie.rs
index 8e8decc..047c7ec 100644
--- a/autofeur_db/src/trie.rs
+++ b/autofeur_db/src/trie.rs
@@ -17,7 +17,7 @@ impl<'a> TrieNode<'a> {
pub fn new<'b>(is_final: bool) -> TrieNode<'b> {
TrieNode {
is_final,
- child_nodes: HashMap::new(),
+ child_nodes: HashMap::with_capacity(256),
child_count: 0,
}
}
@@ -25,7 +25,7 @@ impl<'a> TrieNode<'a> {
pub fn new_root<'b>() -> TrieNode<'b> {
TrieNode {
is_final: false,
- child_nodes: HashMap::new(),
+ child_nodes: HashMap::with_capacity(256),
child_count: 0,
}
}