Fixing clippy warnings (#1660)

This commit is contained in:
Tomasz Drwięga
2016-07-19 09:25:51 +02:00
committed by Gav Wood
parent 340f0b6f58
commit 038862fa9d
9 changed files with 31 additions and 26 deletions

View File

@@ -72,7 +72,7 @@ pub fn take_snapshot(client: &BlockChainClient, mut path: PathBuf, state_db: &Ha
let mut manifest_file = try!(File::create(&path));
try!(manifest_file.write_all(&manifest_data.to_rlp()));
try!(manifest_file.write_all(&manifest_data.into_rlp()));
Ok(())
}
@@ -287,7 +287,7 @@ pub struct ManifestData {
impl ManifestData {
/// Encode the manifest data to rlp.
pub fn to_rlp(self) -> Bytes {
pub fn into_rlp(self) -> Bytes {
let mut stream = RlpStream::new_list(5);
stream.append(&self.state_hashes);
stream.append(&self.block_hashes);
@@ -414,4 +414,4 @@ fn rebuild_account_trie(db: &mut HashDB, account_chunk: &[&[u8]], out_chunk: &mu
*out = (hash, thin_rlp);
}
Ok(())
}
}