improve tree-sitter hl

This commit is contained in:
Michael Chris Lopez
2021-10-04 20:10:29 +08:00
parent 8b2b32c2ee
commit 4cd223c9a2
4 changed files with 18 additions and 10 deletions

View File

@@ -220,21 +220,21 @@ local theme = lush(function()
-- TSConstructor { }; -- For constructor calls and definitions: ` { }` in Lua, and Java constructors.
-- TSConditional { }; -- For keywords related to conditionnals.
-- TSConstant { }; -- For constants
-- TSConstBuiltin { }; -- For constant that are built in the language: `nil` in Lua.
-- TSConstMacro { }; -- For constants that are defined by macros: `NULL` in C.
TSConstBuiltin { Number }; -- For constant that are built in the language: `nil` in Lua.
TSConstMacro { Number }; -- For constants that are defined by macros: `NULL` in C.
-- TSError { }; -- For syntax/parser errors.
-- TSException { }; -- For exception related keywords.
-- TSField { }; -- For fields.
-- TSFloat { }; -- For floats.
-- TSFunction { }; -- For function (calls and definitions).
-- TSFuncBuiltin { }; -- For builtin functions: `table.insert` in Lua.
-- TSFuncBuiltin { }; -- For builtin functions: `print` in Lua.
-- TSFuncMacro { }; -- For macro defined fuctions (calls and definitions): each `macro_rules` in Rust.
-- TSInclude { }; -- For includes: `#include` in C, `use` or `extern crate` in Rust, or `require` in Lua.
-- TSKeyword { }; -- For keywords that don't fall in previous categories.
-- TSKeywordFunction { }; -- For keywords used to define a fuction.
-- TSLabel { }; -- For labels: `label:` in C and `:label:` in Lua.
-- TSMethod { }; -- For method calls and definitions.
-- TSNamespace { }; -- For identifiers referring to modules and namespaces.
TSNamespace { Special }; -- For identifiers referring to modules and namespaces.
-- TSNone { }; -- TODO: docs
-- TSNumber { }; -- For all numbers
-- TSOperator { }; -- For any operator: `+`, but also `->` and `*` in C.
@@ -252,7 +252,7 @@ local theme = lush(function()
-- TSType { }; -- For types.
-- TSTypeBuiltin { }; -- For builtin types.
TSVariable { Identifier }, -- Any variable name that does not have another highlight.
-- TSVariableBuiltin { }; -- Variable names that are defined by the languages, like `this` or `self`.
TSVariableBuiltin { Number }; -- Variable names that are defined by the languages, like `this` or `self`.
TSTag { Special }, -- Tags like html tag names.
-- TSTagDelimiter { }; -- Tag delimiter like `<` `>` `/`