From e895b44291891cd13bd1b50b5fd414c15341b5e0 Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Wed, 25 Feb 2026 22:12:31 +0100 Subject: Define the global scope to a more obscure name MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit By how we define scopes, we needed an internal name for the global scope. All the way back to my first commit 587dd5bb8036 ("Initial commit"), I simply picked "Global". That is troublesome, as it can easily be typed by a human. If a programmer writes a scope with "global" definitions via this scope, this can be messed up with nasm's internal Global scope. Change that to a more obscure name for this internal global scope. If a programmer is so dead from the inside that wants to have a scope named like that, so be it. Signed-off-by: Miquel Sabaté Solà --- lib/xixanta/src/object.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib') diff --git a/lib/xixanta/src/object.rs b/lib/xixanta/src/object.rs index 170d872..c70afb7 100644 --- a/lib/xixanta/src/object.rs +++ b/lib/xixanta/src/object.rs @@ -4,7 +4,7 @@ use crate::opcodes::CONTROL_FUNCTIONS; use std::collections::HashMap; /// The name of the global context as used internally. -const GLOBAL_CONTEXT: &str = "Global"; +const GLOBAL_CONTEXT: &str = "__internal_nasm_global_scope"; /// A Bundle represents a set of bytes that can be encoded as binary data. #[derive(Debug, Default, Clone, Eq, Ord, PartialEq, PartialOrd)] -- cgit v1.2.3