This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#[macro_use] | |
extern crate quickcheck; | |
extern crate rand; | |
extern crate btree; | |
use self::quickcheck::{Arbitrary, Gen}; | |
// The maximum key size. keeping it relatively | |
// small increases the chance of multiple | |
// operations being executed against the same |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct Node<K, V> | |
where | |
K: Ord | |
{ | |
key: K, | |
value: V, | |
left: Option<Box<Node<K, V>>>, | |
right: Option<Box<Node<K, V>>>, | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
struct Node<K, V> | |
where | |
K: Ord + Sized, | |
V: Sized, | |
{ | |
key: K, | |
value: V, | |
left: Option<Box<Node<K, V>>>, | |
right: Option<Box<Node<K, V>>>, | |
} |