Add a fully functioning disassemblere?

This commit is contained in:
2018-06-01 23:43:33 +02:00
parent 0b8e28fb22
commit c6ac7ce4f7
5 changed files with 466 additions and 36 deletions

View File

@@ -15,7 +15,7 @@ use netstack::NetStack;
#[cfg(feature = "bonus:heap")]
use heap::Heap;
const MAGIC_HEADER:u32 = 0x1DEA_DFAD;
pub const MAGIC_HEADER:u32 = 0x1DEA_DFAD;
const ANTI_BS_SIZE:usize = 0xFF;
pub struct Machine {
@@ -85,7 +85,7 @@ impl Machine {
pub fn step(&mut self) -> Result<()> {
match self.block.read_op() {
Ok(Operation::Op(a, func)) => {
Ok(Operation::Op(a, func, _)) => {
if cfg!(feature = "debug:instr") {
println!("{}", a);
println!("Stack: {:?}", self.cur_frame().stack.data);