forked from helix-editor/helix
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Improvements to Meson syntax. (helix-editor#4572)
Co-authored-by: Garrett D'Amore <[email protected]> Co-authored-by: Michael Davis <[email protected]>
- Loading branch information
1 parent
6112b73
commit 1b6c895
Showing
3 changed files
with
51 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,62 +1,62 @@ | ||
(string_literal) @string | ||
(comment) @comment | ||
|
||
(boolean_literal) @constant.builtin.boolean | ||
(integer_literal) @constant.numeric.integer | ||
|
||
(comment) @comment.line | ||
(function_id) @function | ||
(keyword_arg_key) @variable.other.member | ||
(id_expression) @variable | ||
; these are listed first, because they override keyword queries | ||
(function_expression (identifier) @function) | ||
|
||
[ | ||
"if" | ||
"elif" | ||
"else" | ||
"endif" | ||
] @keyword.control.conditional | ||
(assignment_operator) | ||
(additive_operator) | ||
(multiplicative_operator) | ||
(equality_operator) | ||
">=" | ||
"<=" | ||
"<" | ||
">" | ||
"+" | ||
"-" | ||
] @operator | ||
|
||
[ | ||
"foreach" | ||
"endforeach" | ||
] @keyword.control.repeat | ||
(and) | ||
(or) | ||
(not) | ||
(in) | ||
] @keyword.operator | ||
|
||
[ | ||
"break" | ||
"continue" | ||
] @keyword.control | ||
"(" ")" "[" "]" "{" "}" | ||
] @punctuation.bracket | ||
|
||
[ | ||
"not" | ||
"in" | ||
"and" | ||
"or" | ||
] @keyword.operator | ||
(if) | ||
(elif) | ||
(else) | ||
(endif) | ||
] @keyword.control.conditional | ||
|
||
[ | ||
"!" | ||
"+" | ||
"-" | ||
"*" | ||
"/" | ||
"%" | ||
"==" | ||
"!=" | ||
">" | ||
"<" | ||
">=" | ||
"<=" | ||
] @operator | ||
(foreach) | ||
(endforeach) | ||
(break) | ||
(continue) | ||
] @keyword.control.repeat | ||
|
||
(boolean_literal) @constant.builtin.boolean | ||
(int_literal) @constant.numeric.integer | ||
|
||
(keyword_argument keyword: (identifier) @variable.parameter) | ||
(escape_sequence) @constant.character.escape | ||
(bad_escape) @warning | ||
|
||
[ | ||
":" | ||
"," | ||
"." | ||
"," | ||
":" | ||
] @punctuation.delimiter | ||
|
||
[ | ||
"(" | ||
")" | ||
"[" | ||
"]" | ||
"{" | ||
"}" | ||
] @punctuation.bracket | ||
(string_literal) | ||
(fstring_literal) | ||
] @string | ||
|
||
(identifier) @variable |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,17 @@ | ||
; Indentation queries for helix | ||
[ | ||
(method_expression) | ||
(function_expression) | ||
(array_literal) | ||
(dictionary_literal) | ||
(selection_statement) | ||
(iteration_statement) | ||
] @indent | ||
|
||
; question - what about else, elif | ||
[ | ||
")" | ||
"]" | ||
"}" | ||
"endif" | ||
"endforeach" | ||
(endif) | ||
(endforeach) | ||
] @outdent |