aboutsummaryrefslogtreecommitdiff
path: root/src/armv7
diff options
context:
space:
mode:
Diffstat (limited to 'src/armv7')
-rw-r--r--src/armv7/display.rs2
-rw-r--r--src/armv7/thumb.rs10
2 files changed, 8 insertions, 4 deletions
diff --git a/src/armv7/display.rs b/src/armv7/display.rs
index d8d67a2..ba89f50 100644
--- a/src/armv7/display.rs
+++ b/src/armv7/display.rs
@@ -1554,7 +1554,7 @@ mod buffer_sink {
/// into.
///
/// SAFETY: callers must print at most one instruction into this handle.
- unsafe fn write_handle(&mut self) -> yaxpeax_arch::display::InstructionTextSink {
+ unsafe fn write_handle(&mut self) -> yaxpeax_arch::display::InstructionTextSink<'_> {
self.content.clear();
// Safety: `content` was just cleared, so writing begins at the start of the buffer.
// `content`is large enough to hold a fully-formatted instruction (see
diff --git a/src/armv7/thumb.rs b/src/armv7/thumb.rs
index b59754c..e8b050a 100644
--- a/src/armv7/thumb.rs
+++ b/src/armv7/thumb.rs
@@ -1,3 +1,7 @@
+// names from the manual are like, `Rt`, `CRd`, etc, which are not typical snake
+// case and provoke style warnings.
+#![allow(non_snake_case)]
+
use yaxpeax_arch::Arch;
use crate::armv7::{
@@ -4467,7 +4471,7 @@ fn decode_table_a6_30(decoder: &InstDecoder, inst: &mut Instruction, instr2: Bit
// MCR, MCR2 (A8-477)
inst.opcode = Opcode::MCR(coproc, opc1, opc2, is_2);
inst.operands = [
- Operand::Reg(Reg::from_u8(CRd)),
+ Operand::Reg(Reg::from_u8(Rt)),
Operand::CReg(CReg::from_u8(CRn)),
Operand::CReg(CReg::from_u8(CRm)),
Operand::Nothing,
@@ -4475,10 +4479,10 @@ fn decode_table_a6_30(decoder: &InstDecoder, inst: &mut Instruction, instr2: Bit
} else {
// MRC, MRC2 (A8-493)
inst.opcode = Opcode::MRC(coproc, opc1, opc2, is_2);
- let dest = if CRd == 0b1111 {
+ let dest = if Rt == 0b1111 {
Operand::StatusRegMask(StatusRegMask::APSR_NZCV)
} else {
- Operand::Reg(Reg::from_u8(CRd))
+ Operand::Reg(Reg::from_u8(Rt))
};
inst.operands = [
dest,