From 81c6cdd1b508402edc16ab2ae88379d951c8cfa6 Mon Sep 17 00:00:00 2001 From: iximeow Date: Sat, 19 Oct 2019 22:05:22 -0700 Subject: warnings-b-gone --- src/lib.rs | 5 ----- 1 file changed, 5 deletions(-) (limited to 'src') diff --git a/src/lib.rs b/src/lib.rs index bf9f7d9..ad89bd3 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -2,8 +2,6 @@ #[macro_use] extern crate serde_derive; #[cfg(feature="use-serde")] extern crate serde; -#[cfg(feature="use-serde")] -use serde::{Serialize, Deserialize}; extern crate yaxpeax_arch; extern crate termion; @@ -2186,7 +2184,6 @@ fn read_E_anybank>(bytes_iter: &mut T, instr: &mut Instruct #[inline] fn width_to_gp_reg_bank(width: u8, rex: bool) -> RegisterBank { - use std::hint::unreachable_unchecked; match width { 1 => return if rex { RegisterBank::rB } else { RegisterBank::B }, 2 => return RegisterBank::W, @@ -2198,7 +2195,6 @@ fn width_to_gp_reg_bank(width: u8, rex: bool) -> RegisterBank { pub fn read_instr>(mut bytes_iter: T, instruction: &mut Instruction) -> Option<()> { let mut alternate_opcode_map: Option = None; - use std::hint::unreachable_unchecked; // use std::intrinsics::unlikely; instruction.prefixes = Prefixes::new(0); let record: OpcodeRecord = loop { @@ -3240,7 +3236,6 @@ pub fn read_operands>(mut bytes_iter: T, instruction: &mut _ => { instruction.operands = [Operand::Nothing, Operand::Nothing]; instruction.opcode = Opcode::Invalid; - // use std::hint::unreachable_unchecked; return None; // Err(format!("unsupported operand code: {:.unwrap()}", operand_code)); // unsafe { unreachable_unchecked(); } } -- cgit v1.1