Remove unused code (#9884)
This commit is contained in:
parent
e4c53a460e
commit
aafe527d4a
@ -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()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user