Remove unused code (#9884)

This commit is contained in:
zhangyaning 2018-11-08 20:20:02 +08:00 committed by Niklas Adolfsson
parent e4c53a460e
commit aafe527d4a

View File

@ -38,7 +38,6 @@ pub trait Memory {
fn read_slice(&self, offset: U256, size: U256) -> &[u8]; fn read_slice(&self, offset: U256, size: U256) -> &[u8];
/// Retrieve writeable part of memory /// Retrieve writeable part of memory
fn writeable_slice(&mut self, offset: U256, size: U256) -> &mut[u8]; fn writeable_slice(&mut self, offset: U256, size: U256) -> &mut[u8];
fn dump(&self);
/// Convert memory into return data. /// Convert memory into return data.
fn into_return_data(self, offset: U256, size: U256) -> ReturnData; fn into_return_data(self, offset: U256, size: U256) -> ReturnData;
} }
@ -51,14 +50,6 @@ pub fn is_valid_range(off: usize, size: usize) -> bool {
} }
impl Memory for Vec<u8> { impl Memory for Vec<u8> {
fn dump(&self) {
println!("MemoryDump:");
for i in self.iter() {
println!("{:02x} ", i);
}
println!("");
}
fn size(&self) -> usize { fn size(&self) -> usize {
self.len() self.len()
} }