diff options
-rw-r--r-- | src/display.rs | 10 | ||||
-rw-r--r-- | src/lib.rs | 4 |
2 files changed, 5 insertions, 9 deletions
diff --git a/src/display.rs b/src/display.rs index b51ae9b..4593f20 100644 --- a/src/display.rs +++ b/src/display.rs @@ -1,12 +1,8 @@ use ::{MSP430, Operand, Opcode, Instruction, Width}; -use std::collections::HashMap; use std::fmt::{Display, Formatter}; -use std::hash::Hash; -use std::rc::Rc; use std; -use termion::color; -use yaxpeax_arch::{Arch, Colorize, ColorSettings, LengthedInstruction, ShowContextual}; +use yaxpeax_arch::{Arch, Colorize, ColorSettings, ShowContextual}; impl Display for Instruction { fn fmt(&self, f: &mut Formatter) -> Result<(), std::fmt::Error> { @@ -17,7 +13,7 @@ impl Display for Instruction { } impl <T: std::fmt::Write> ShowContextual<<MSP430 as Arch>::Address, [Option<String>], T> for Instruction { - fn contextualize(&self, colors: Option<&ColorSettings>, address: <MSP430 as Arch>::Address, context: Option<&[Option<String>]>, out: &mut T) -> std::fmt::Result { + fn contextualize(&self, _colors: Option<&ColorSettings>, _address: <MSP430 as Arch>::Address, _context: Option<&[Option<String>]>, out: &mut T) -> std::fmt::Result { write!(out, "{}", self.opcode)?; match self.op_width { Width::B => { write!(out, ".b")? }, @@ -84,7 +80,7 @@ impl Display for Operand { } impl <T: std::fmt::Write> Colorize<T> for Operand { - fn colorize(&self, colors: Option<&ColorSettings>, out: &mut T) -> std::fmt::Result { + fn colorize(&self, _colors: Option<&ColorSettings>, out: &mut T) -> std::fmt::Result { fn signed_hex(num: i16) -> String { if num >= 0 { format!("+{:#x}", num) @@ -2,8 +2,8 @@ #[macro_use] extern crate serde_derive; #[cfg(feature="use-serde")] extern crate serde; -#[cfg(feature="use-serde")] -use serde::{Serialize, Deserialize}; +//#[cfg(feature="use-serde")] +//use serde::{Serialize, Deserialize}; extern crate yaxpeax_arch; extern crate termion; |