diff --git a/Cargo.toml b/Cargo.toml index 8dc2bd2a7..8450bf1b8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -15,7 +15,6 @@ flate2 = "0.2" rocksdb = "0.2.1" evmjit = { path = "rust-evmjit", optional = true } -rustc-serialize = "0.3" [features] jit = ["evmjit"] diff --git a/src/extras.rs b/src/extras.rs index d9a0fa08b..f394e790b 100644 --- a/src/extras.rs +++ b/src/extras.rs @@ -62,15 +62,14 @@ pub struct BlockDetails { impl Decodable for BlockDetails { fn decode(decoder: &D) -> Result where D: Decoder { - decoder.read_list(| d | { - let details = BlockDetails { - number: try!(Decodable::decode(&d[0])), - total_difficulty: try!(Decodable::decode(&d[1])), - parent: try!(Decodable::decode(&d[2])), - children: try!(Decodable::decode(&d[3])) - }; - Ok(details) - }) + let d = try!(decoder.as_list()); + let details = BlockDetails { + number: try!(Decodable::decode(&d[0])), + total_difficulty: try!(Decodable::decode(&d[1])), + parent: try!(Decodable::decode(&d[2])), + children: try!(Decodable::decode(&d[3])) + }; + Ok(details) } } diff --git a/src/lib.rs b/src/lib.rs index 3ba3b63be..cc1240233 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -76,7 +76,6 @@ extern crate flate2; extern crate rocksdb; extern crate env_logger; -extern crate rustc_serialize; #[cfg(feature = "jit" )] extern crate evmjit; extern crate ethcore_util as util;