use std::io::{Read, stdin}; use hbvm::{validate::validate, vm::Vm, RuntimeErrors}; fn main() -> Result<(), Box> { let mut prog = vec![]; stdin().read_to_end(&mut prog)?; if let Err(e) = validate(&prog) { eprintln!("Program validation error: {e:?}"); return Ok(()); } else { unsafe { let mut vm = Vm::new_unchecked(&prog); vm.memory.insert_test_page(); vm.run(); println!("{:?}", vm.registers); } } Ok(()) } pub fn time() -> u32 { 9 }