fixed some errors

This commit is contained in:
Himujjal 2021-04-02 03:47:34 +05:30 committed by Stephan Seitz
parent 9b5e82ff9d
commit 83bfcde7c2
5 changed files with 15 additions and 11 deletions

View file

@ -10,6 +10,7 @@
(test_expression)
(struct_expression)
(anonymous_struct_enum)
(anonymous_array_expr)
(union_expression)
(enum_expression)
] @fold

View file

@ -1,4 +1,3 @@
; Types
; Zig
@ -13,23 +12,23 @@
; function definition
(function_signature
(identifier) @function
)
name: (identifier) @function)
(function_declaration (identifier) @function)
(function_declaration
name: (identifier) @function)
; Function calls
; (call_expression
; function: (identifier)) @function
(call_expression
function: (identifier) @function)
(build_in_call_expr
function: (identifier) @function.builtin
function: (identifier) @function
)
;; other identifiers
(type_identifier) @type
(primitive_type) @type.builtin
(field_identifier) @property
(field_identifier) @field
(line_comment) @comment
(doc_comment) @comment
@ -38,14 +37,14 @@
(integer_literal) @number
(float_literal) @number
(boolean_literal) @constant.builtin
(boolean_literal) @boolean
(undefined_literal) @constant.builtin
(null_literal) @constant.builtin
(ERROR) @error
; (ERROR) @error
(string_literal) @string
(multiline_string_literal "\\\\" @string.special)
(multiline_string_literal) @string
(escape_sequence) @constant.builtin

View file

@ -11,6 +11,7 @@
(struct_expression)
(struct_construction)
(anonymous_struct_enum)
(anonymous_array_expr)
(enum_expression)
(union_expression)
] @indent

View file

@ -0,0 +1 @@
(line_comment) @comment

View file

@ -1,3 +1,4 @@
(function_declaration
name: (identifier) @definition.function
)
@ -22,4 +23,5 @@
(while_expression)
(for_expression)
(test_expression)
(anonymous_array_expr)
] @scope