From 168a3fd34824adc9c6a606cd144219701f15cccf Mon Sep 17 00:00:00 2001 From: Mason Reed Date: Wed, 17 Dec 2025 21:23:46 -0500 Subject: [Rust] Replace `log` with `tracing` - Added more documentation - Replaced global named logger for plugins, fixing the issue when the CU has multiple (e.g. statically linked demo) - Simplified some misc code This is a breaking change, but I believe there is no better time to make it, we cannot continue to use the `log` crate, it is too limited for our needs. --- arch/msp430/src/architecture.rs | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'arch/msp430/src/architecture.rs') diff --git a/arch/msp430/src/architecture.rs b/arch/msp430/src/architecture.rs index ef4c503a..996d3c4a 100644 --- a/arch/msp430/src/architecture.rs +++ b/arch/msp430/src/architecture.rs @@ -8,7 +8,7 @@ use binaryninja::{ UnusedIntrinsic, UnusedRegisterStack, }, disassembly::{InstructionTextToken, InstructionTextTokenKind}, - Endianness, + tracing, Endianness, }; use msp430_asm::{ @@ -21,7 +21,6 @@ use binaryninja::architecture::{ }; use binaryninja::low_level_il::expression::ValueExpr; use binaryninja::low_level_il::{LowLevelILMutableExpression, LowLevelILMutableFunction}; -use log::error; const MIN_MNEMONIC: usize = 9; @@ -321,7 +320,7 @@ impl Architecture for Msp430 { match id.try_into() { Ok(flag) => Some(flag), Err(_) => { - error!("invalid flag id {}", id); + tracing::error!("invalid flag id {}", id); None } } @@ -331,7 +330,7 @@ impl Architecture for Msp430 { match id.try_into() { Ok(flag_write) => Some(flag_write), Err(_) => { - error!("invalid flag write id {}", id); + tracing::error!("invalid flag write id {}", id); None } } -- cgit v1.3.1