diff options
| author | Nathan Lee <me@nwlee.tech> | 2026-06-10 22:27:34 -0500 |
|---|---|---|
| committer | Nathan Lee <me@nwlee.tech> | 2026-06-10 22:27:34 -0500 |
| commit | 0f4993d181bb4dd09a8f2613dd82f267b355fe7e (patch) | |
| tree | b213a68dd99c73360133e7c3d8ded4b87ed3a6b0 /src/main.rs | |
| parent | f94c087120bf2a241dda51d6311c565dd03b96be (diff) | |
chore: lint
Diffstat (limited to 'src/main.rs')
| -rw-r--r-- | src/main.rs | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/main.rs b/src/main.rs index 48ce998..bbf89b6 100644 --- a/src/main.rs +++ b/src/main.rs @@ -3,12 +3,12 @@ pub mod mem; pub mod state; use crate::core::*; +use crate::mem::Memory; +use crate::state::CpuState; use std::collections::HashSet; use std::io; use std::io::Write; use std::process::exit; -use crate::mem::Memory; -use crate::state::CpuState; const MEMORY_SIZE: usize = 64 * 1024 * 1024; const REGISTER_NAME_WIDTH: u32 = 0b11111; @@ -201,8 +201,7 @@ fn handle_instruction(state: &mut CpuState) { // ecall eprintln!( "TRAP! syscall {} with gp state {:?}", - state.registers[17], - pc + state.registers[17], pc ); } // ecall (ebreak not implemented) 0b0101111 => { @@ -321,4 +320,4 @@ fn handle_instruction(state: &mut CpuState) { } state.pc += 4; -}
\ No newline at end of file +} |
