aboutsummaryrefslogtreecommitdiff
path: root/runtime/queries/julia/highlights.scm
diff options
context:
space:
mode:
authorChristoph Horn2022-08-22 12:22:48 +0000
committerMichael Davis2022-08-24 16:55:47 +0000
commit77f11bf272b1e7286f1ad77cba29ede7393665c3 (patch)
tree9375875ea6129f12c15414f340aed63ec79a7929 /runtime/queries/julia/highlights.scm
parent2b16fd43f901753fcedd87b9687ce535c4108203 (diff)
Julia queries: update grammar, fix breaking changes
Diffstat (limited to 'runtime/queries/julia/highlights.scm')
-rw-r--r--runtime/queries/julia/highlights.scm23
1 files changed, 14 insertions, 9 deletions
diff --git a/runtime/queries/julia/highlights.scm b/runtime/queries/julia/highlights.scm
index 7c447985..31848888 100644
--- a/runtime/queries/julia/highlights.scm
+++ b/runtime/queries/julia/highlights.scm
@@ -1,10 +1,7 @@
-[
- (triple_string)
- (string)
-] @string
+(string_literal) @string
-(string
+(prefixed_string_literal
prefix: (identifier) @constant.builtin)
(macro_identifier) @function.macro
@@ -80,7 +77,9 @@
(struct_definition
name: (identifier) @type)
-(number) @constant.numeric.integer
+(integer_literal) @constant.numeric.integer
+(float_literal) @constant.numeric.float
+
(range_expression
(identifier) @constant.numeric.integer
(eq? @constant.numeric.integer "end"))
@@ -89,7 +88,10 @@
(identifier) @constant.numeric.integer
(eq? @constant.numeric.integer "end")))
(coefficient_expression
- (number)
+ [
+ (integer_literal)
+ (float_literal)
+ ]
(identifier) @constant.builtin)
;; TODO: operators.
@@ -117,7 +119,10 @@
(function_definition ["function" "end"] @keyword.function)
-(comment) @comment
+[
+ (line_comment)
+ (block_comment)
+] @comment
[
"const"
@@ -171,7 +176,7 @@
(((identifier) @constant.builtin.boolean) (#eq? @constant.builtin.boolean "false"))
-["::" ":" "." "," "..." "!"] @punctuation.delimiter
+["::" ":" "." "," "..."] @punctuation.delimiter
["[" "]" "(" ")" "{" "}"] @punctuation.bracket
["="] @operator