Skip to content

Commit 04534f5

Browse files
committed
fmt
1 parent 93c049d commit 04534f5

File tree

1 file changed

+3
-8
lines changed
  • objdiff-core/src/arch/superh

1 file changed

+3
-8
lines changed

objdiff-core/src/arch/superh/mod.rs

Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
use alloc::{string::String, vec::Vec};
2+
use std::collections::HashMap;
23

34
use anyhow::{Result, bail};
45
use object::elf;
@@ -7,12 +8,10 @@ use crate::{
78
arch::{Arch, superh::disasm::sh2_disasm},
89
diff::{DiffObjConfig, display::InstructionPart},
910
obj::{
10-
InstructionRef, Relocation, RelocationFlags, ResolvedInstructionRef, ScannedInstruction
11+
InstructionRef, Relocation, RelocationFlags, ResolvedInstructionRef, ScannedInstruction,
1112
},
1213
};
1314

14-
use std::collections::HashMap;
15-
1615
pub mod disasm;
1716

1817
#[derive(Debug)]
@@ -22,7 +21,6 @@ impl ArchSuperH {
2221
pub fn new(_file: &object::File) -> Result<Self> { Ok(Self {}) }
2322
}
2423

25-
2624
struct DataInfo {
2725
address: u64,
2826
size: u32,
@@ -104,8 +102,6 @@ impl Arch for ArchSuperH {
104102
}
105103

106104
let pos = resolved.ins_ref.address - resolved.symbol.address;
107-
let a = resolved.ins_ref.address;
108-
let b = resolved.symbol.address;
109105

110106
// add the data info
111107
if let Some(value) = data_offsets.get(&pos) {
@@ -217,8 +213,7 @@ mod test {
217213
use std::fmt::{self, Display};
218214

219215
use super::*;
220-
use crate::obj::InstructionArg;
221-
use crate::obj::Symbol;
216+
use crate::obj::{InstructionArg, Symbol};
222217

223218
impl Display for InstructionPart<'_> {
224219
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {

0 commit comments

Comments
 (0)