From 0bc967cf0f873a27dca1e7f3a723a0c53db9a68f Mon Sep 17 00:00:00 2001 From: Brandon Miller Date: Wed, 6 Aug 2025 16:10:02 -0400 Subject: Add a new line disassembly text token --- rust/src/disassembly.rs | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'rust/src') diff --git a/rust/src/disassembly.rs b/rust/src/disassembly.rs index c1021197..ed9b0854 100644 --- a/rust/src/disassembly.rs +++ b/rust/src/disassembly.rs @@ -545,6 +545,10 @@ pub enum InstructionTextTokenKind { // TODO: Explain what this is hash: Option, }, + NewLine { + // Offset into instruction that this new line is associated with + value: u64, + }, } impl InstructionTextTokenKind { @@ -721,6 +725,7 @@ impl InstructionTextTokenKind { }, } } + BNInstructionTextTokenType::NewLineToken => Self::NewLine { value: value.value }, } } @@ -756,6 +761,7 @@ impl InstructionTextTokenKind { InstructionTextTokenKind::ExternalSymbol { value, .. } => Some(*value), InstructionTextTokenKind::StackVariable { variable_id, .. } => Some(*variable_id), InstructionTextTokenKind::CollapseStateIndicator { hash, .. } => *hash, + InstructionTextTokenKind::NewLine { value, .. } => Some(*value), _ => None, } } @@ -925,6 +931,7 @@ impl From for BNInstructionTextTokenType { InstructionTextTokenKind::CollapseStateIndicator { .. } => { BNInstructionTextTokenType::CollapseStateIndicatorToken } + InstructionTextTokenKind::NewLine { .. } => BNInstructionTextTokenType::NewLineToken, } } } -- cgit v1.3.1