diff options
author | iximeow <me@iximeow.net> | 2020-05-03 14:06:21 -0700 |
---|---|---|
committer | iximeow <me@iximeow.net> | 2020-05-03 14:06:21 -0700 |
commit | 2b33746fd0f947b0343981941cc49f59e88daa4b (patch) | |
tree | cfc2bc6818306be8cc3d2c996c3b918ebde83713 /src/lib.rs | |
parent | a3d7fba380fad8e66529b908fb0a09024a41d699 (diff) |
version bump, bumping yaxpeax-arch to 0.0.40.0.3
Diffstat (limited to 'src/lib.rs')
-rw-r--r-- | src/lib.rs | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -9,7 +9,7 @@ use std::fmt; extern crate yaxpeax_arch; -use yaxpeax_arch::{Arch, Decoder, LengthedInstruction}; +use yaxpeax_arch::{Arch, AddressDiff, Decoder, LengthedInstruction}; pub mod consts; pub mod display; @@ -37,9 +37,9 @@ pub struct Instruction { } impl LengthedInstruction for Instruction { - type Unit = <PIC18 as Arch>::Address; + type Unit = AddressDiff<<PIC18 as Arch>::Address>; fn min_size() -> Self::Unit { - 2 + AddressDiff::from_const(2) } fn len(&self) -> Self::Unit { match self.opcode { @@ -49,9 +49,9 @@ impl LengthedInstruction for Instruction { | Opcode::CALL | Opcode::LFSR | Opcode::GOTO => { - 4 + AddressDiff::from_const(4) }, - _ => 2 + _ => AddressDiff::from_const(2) } } } |