From f0624b8929e6ead3f2d8b1939dc7f094c539bee1 Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Tue, 5 Nov 2024 13:39:16 +0100 Subject: Re-work the handling of segments in the assembler MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit There were a lot of assumptions on the assembler that stemmed from a fundamental missunderstanding from my side on how segments are laid out on the final file. This commit is the first step to address this. Signed-off-by: Miquel Sabaté Solà --- lib/xixanta/src/opcodes.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/xixanta/src/opcodes.rs') diff --git a/lib/xixanta/src/opcodes.rs b/lib/xixanta/src/opcodes.rs index 4e336ba..1a2b318 100644 --- a/lib/xixanta/src/opcodes.rs +++ b/lib/xixanta/src/opcodes.rs @@ -724,7 +724,7 @@ lazy_static! { functions.insert(String::from(".endscope"), Control { control_type: ControlType::EndScope, has_identifier: false, required_args: Some(0), touches_context: true }); functions.insert(String::from(".endproc"), Control { control_type: ControlType::EndProc, has_identifier: false, required_args: Some(0), touches_context: true }); functions.insert(String::from(".endmacro"), Control { control_type: ControlType::EndMacro, has_identifier: false, required_args: Some(0), touches_context: true }); - functions.insert(String::from(".segment"), Control { control_type: ControlType::Segment, has_identifier: false, required_args: Some(1), touches_context: true }); + functions.insert(String::from(".segment"), Control { control_type: ControlType::Segment, has_identifier: false, required_args: Some(1), touches_context: false }); functions.insert(String::from(".byte"), Control { control_type: ControlType::Byte, has_identifier: false, required_args: None, touches_context: false }); functions.insert(String::from(".db"), Control { control_type: ControlType::Byte, has_identifier: false, required_args: None, touches_context: false }); functions.insert(String::from(".word"), Control { control_type: ControlType::Word, has_identifier: false, required_args: None, touches_context: false }); -- cgit v1.2.3