From 948ad7f2bda3495faebf39d1bb903f863e9ad596 Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Tue, 3 Feb 2026 10:49:10 +0100 Subject: Ensure __fallthrough__ is not considered a valid identifier MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Miquel Sabaté Solà --- lib/xixanta/src/node.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'lib/xixanta') diff --git a/lib/xixanta/src/node.rs b/lib/xixanta/src/node.rs index 5093ab3..7a5cf3d 100644 --- a/lib/xixanta/src/node.rs +++ b/lib/xixanta/src/node.rs @@ -40,7 +40,10 @@ impl PString { } // You cannot assign into a name which is reserved. - if matches!(self.value.to_lowercase().as_str(), "x" | "y" | "a") { + if matches!( + self.value.to_lowercase().as_str(), + "x" | "y" | "a" | "__fallthrough__" + ) { return Err(format!("cannot use reserved name '{}'", self.value)); } -- cgit v1.2.3