From b8fea9bcb14ea10e618c539c400139dd43d90e02 Mon Sep 17 00:00:00 2001 From: Christian Hesse Date: Mon, 5 Jan 2026 15:01:19 +0100 Subject: support lua 5.5... ... and replace the functions for unsigned integers with their signed equivalents, using a type cast where needed. Actually the functions for unsigned integers were deprecated since lua 5.3... https://www.lua.org/manual/5.3/manual.html#8.3 Also lua_newstate() requires a third argument since 5.5... https://www.lua.org/manual/5.5/manual.html#8.3 Finally the key in a for loop is now const, so use a temporary variable instead. --- lua/lexers/lexer.lua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lua/lexers/lexer.lua') diff --git a/lua/lexers/lexer.lua b/lua/lexers/lexer.lua index 7251ed2..b37e0de 100644 --- a/lua/lexers/lexer.lua +++ b/lua/lexers/lexer.lua @@ -1091,9 +1091,9 @@ function M.embed(lexer, child, start_rule, end_rule) if child._WORDLISTS then for name, i in pairs(child._WORDLISTS) do if type(name) == 'string' and type(i) == 'number' then - name = child._name .. '.' .. name - lexer:word_match(name) -- for side effects - lexer:set_word_list(name, child._WORDLISTS[i]) + tname = child._name .. '.' .. name + lexer:word_match(tname) -- for side effects + lexer:set_word_list(tname, child._WORDLISTS[i]) end end end -- cgit v1.2.3