Drop old cairo grammar, alias to rust for now

pull/7146/head
Blaž Hrastnik 2 years ago
parent 207829eefe
commit c6d1430243
No known key found for this signature in database
GPG Key ID: 1238B9C4AD889640

@ -1700,10 +1700,9 @@ file-types = ["cairo"]
roots = [] roots = []
comment-token = "//" comment-token = "//"
indent = { tab-width = 4, unit = " " } indent = { tab-width = 4, unit = " " }
# auto-format = true
[[grammar]] language-server = { command = "cairo-language-server", args = [] }
name = "cairo" grammar = "rust"
source = { git = "https://github.com/archseer/tree-sitter-cairo", rev = "b249662a1eefeb4d71c9529cdd971e74fecc10fe" }
[[language]] [[language]]
name = "cpon" name = "cpon"

@ -1,94 +1 @@
(ERROR) @error ; inherits: rust
((identifier) @constant
(#match? @constant "^[A-Z][A-Z\\d_]+$"))
((identifier_def) @constant
(#match? @constant "^[A-Z][A-Z\\d_]+$"))
((identifier) @namespace
(#match? @namespace "^[A-Z]"))
((identifier_def) @namespace
(#match? @namespace "^[A-Z]"))
(identifier "." @punctuation)
(function_call (identifier) @function)
(func (identifier_def) @function)
(string) @string
(atom_short_string) @string
(code_element_directive) @keyword.directive
"return" @keyword
(number) @constant.numeric
(atom_hex_number) @constant.numeric
(comment) @comment
"*" @special
(type) @type
[
"felt"
; "codeoffset"
] @type.builtin
[
"if"
"else"
"assert"
"with"
"with_attr"
] @keyword.control
[
"from"
"import"
"func"
"namespace"
] @keyword ; keyword.declaration
[
"let"
"const"
"local"
"struct"
"alloc_locals"
"tempvar"
] @keyword
(decorator) @attribute
[
"="
"+"
"-"
"*"
"/"
; "%"
; "!"
; ">"
; "<"
; "\\"
; "&"
; "?"
; "^"
; "~"
"=="
"!="
"new"
] @operator
[
"("
")"
"["
"]"
"{"
"}"
] @punctuation.bracket
[
","
":"
] @punctuation.delimiter

@ -1,5 +1,3 @@
((hint) @injection.content ([(line_comment) (block_comment)] @injection.content
(#set! injection.language "python"))
((comment) @injection.content
(#set! injection.language "comment")) (#set! injection.language "comment"))

Loading…
Cancel
Save