[−][src]Macro debug_tree::add_leaf_value_to
Adds a leaf to given tree with the given value
argument
Arguments
tree
- The tree that the leaf should be added tovalue
- An expression that implements theDisplay
trait.
Example
#[macro_use] use debug_tree::{TreeBuilder, add_leaf_value_to}; fn main() { let tree = TreeBuilder::new(); let value = add_leaf_value_to!(tree, 5 * 4 * 3 * 2); assert_eq!(120, value); assert_eq!("120", &tree.peek_string()); }