(&self)
| 58 | } |
| 59 | } |
| 60 | |
| 61 | pub fn bytecode_u64_array(&self) -> Result<Vec<u64>, ParseIntError> { |
| 62 | let bytecodes: Vec<&str> = self.bytecode.split('\n').collect(); |
| 63 | bytecodes |
| 64 | .iter() |
| 65 | .map(|&c| { |
| 66 | let instruction_without_prefix = c.trim_start_matches("0x"); |
| 67 | u64::from_str_radix(instruction_without_prefix, 16) |
| 68 | }) |
| 69 | .collect() |
| 70 | } |
| 71 | } |
| 72 | |
| 73 | #[derive(Debug, Clone)] |