From 59e4bb73cf9370d2337b6f46e05c948567170008 Mon Sep 17 00:00:00 2001 From: Vincent Emonet Date: Thu, 21 Dec 2023 17:11:39 +0100 Subject: [PATCH] fix: Fix print --- README.md | 2 +- src/trie.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2b01818..7c2f3a8 100644 --- a/README.md +++ b/README.md @@ -91,7 +91,7 @@ assert_eq!(trie.get_value("app".bytes()), Some("App")); assert_eq!(trie.get_value("none".bytes()), None); for (k, v) in trie.iter() { - println!("kv: {} {}", k, v); + println!("kv: {:?} {}", k, v); } ``` diff --git a/src/trie.rs b/src/trie.rs index 4d55c67..8ef0840 100644 --- a/src/trie.rs +++ b/src/trie.rs @@ -386,7 +386,7 @@ where type Item = (Vec, V); // Yield key-value pairs fn next(&mut self) -> Option { - while let Some((node_id, mut path)) = self.stack.pop() { + while let Some((node_id, path)) = self.stack.pop() { let node = &self.trie.nodes[node_id]; // Push children to the stack with updated path for &(ref key_part, child_id) in &node.children {