diff --git a/bench_log.rs b/bench_log.rs index 5ba68ab7..587c1c6a 100644 --- a/bench_log.rs +++ b/bench_log.rs @@ -453,11 +453,11 @@ impl Log { #[bench] fn bench_encoder(b: &mut Bencher) { let log = Log::new(); - let json = serialize::json::Encoder::str_encode(&log); + let json = serialize::json::encode(&log); let _len = json.len(); b.iter(|| { - let _ = serialize::json::Encoder::str_encode(&log); + let _ = serialize::json::encode(&log); }); } diff --git a/json.rs b/json.rs index b71020e4..8553936f 100644 --- a/json.rs +++ b/json.rs @@ -3691,7 +3691,7 @@ mod bench { let mut list = vec!(); for _ in range(0, count) { - list.push(json::Object(box treemap!( + list.push(json::Object(treemap!( "a".to_string() => json::Boolean(true), "b".to_string() => json::Null, "c".to_string() => json::Number(3.1415), @@ -3703,7 +3703,7 @@ mod bench { )) ))); } - list.push(json::Object(box TreeMap::new())); + list.push(json::Object(TreeMap::new())); json::List(list) }