From 6ece0ca4e624ff1d3a1337f0984074884ce292be Mon Sep 17 00:00:00 2001 From: Christian Clason Date: Sat, 12 Mar 2022 20:17:11 +0100 Subject: fix(lua): restore precedence for @variable.builtin and @constant.builtin --- queries/lua/highlights.scm | 26 ++++++++++++-------------- 1 file changed, 12 insertions(+), 14 deletions(-) (limited to 'queries/lua') diff --git a/queries/lua/highlights.scm b/queries/lua/highlights.scm index ce3214310..1beddb5e3 100644 --- a/queries/lua/highlights.scm +++ b/queries/lua/highlights.scm @@ -1,15 +1,3 @@ -;;; Builtins - -[ - (false) - (true) -] @boolean - -(nil) @constant.builtin - -((identifier) @variable.builtin - (#match? @variable.builtin "self")) - ;; Keywords "return" @keyword.return @@ -140,13 +128,23 @@ (identifier) @variable -;; Constants +((identifier) @variable.builtin + (#match? @variable.builtin "self")) -(vararg_expression) @constant +;; Constants ((identifier) @constant (#lua-match? @constant "^[A-Z][A-Z_0-9]*$")) +(vararg_expression) @constant + +(nil) @constant.builtin + +[ + (false) + (true) +] @boolean + ;; Tables (field name: (identifier) @field) -- cgit v1.2.3-70-g09d2