From a17981879d3424a6b27738f0e9102cbe8b781b2b Mon Sep 17 00:00:00 2001 From: Lars Mueller Date: Tue, 4 Jan 2022 13:44:01 +0100 Subject: [PATCH] Make is_identifier pattern locale-independent --- text.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/text.lua b/text.lua index 05a6eb5..448fa3a 100644 --- a/text.lua +++ b/text.lua @@ -183,7 +183,7 @@ function is_keyword(text) end function is_identifier(text) - return (not keywords[text]) and text:match"^[%a_][%a%d_]*$" + return (not keywords[text]) and text:match"^[A-Za-z_][A-Za-z%d_]*$" end -- Export environment