mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-17 10:50:06 -04:00
Add Codeql indents.scm
This commit is contained in:
parent
ac05d4db50
commit
3472947027
2 changed files with 28 additions and 5 deletions
|
|
@ -105,9 +105,9 @@
|
||||||
(moduleExpr (simpleId) @namespace)
|
(moduleExpr (simpleId) @namespace)
|
||||||
(module name: (moduleName) @namespace)
|
(module name: (moduleName) @namespace)
|
||||||
|
|
||||||
(dataclass name: (className) @type)
|
(dataclass name: (className) @class)
|
||||||
(datatype name: (className) @type)
|
(datatype name: (className) @class)
|
||||||
(typeExpr name: (className) @type)
|
(typeExpr name: (className) @class)
|
||||||
|
|
||||||
(importModuleExpr name: (simpleId) @variable)
|
(importModuleExpr name: (simpleId) @variable)
|
||||||
(qualModuleExpr name: (simpleId) @variable)
|
(qualModuleExpr name: (simpleId) @variable)
|
||||||
|
|
@ -118,9 +118,10 @@
|
||||||
|
|
||||||
(string) @string
|
(string) @string
|
||||||
|
|
||||||
(charpred (className) @function)
|
|
||||||
(aritylessPredicateExpr (literalId) @function)
|
(aritylessPredicateExpr (literalId) @function)
|
||||||
(predicateName) @function
|
(memberPredicate name: (predicateName) @function)
|
||||||
|
(classlessPredicate name: (predicateName) @function)
|
||||||
|
(charpred (className) @function)
|
||||||
|
|
||||||
[
|
[
|
||||||
(line_comment)
|
(line_comment)
|
||||||
|
|
|
||||||
22
queries/ql/indents.scm
Normal file
22
queries/ql/indents.scm
Normal file
|
|
@ -0,0 +1,22 @@
|
||||||
|
[
|
||||||
|
(dataclass)
|
||||||
|
(charpred)
|
||||||
|
(memberPredicate)
|
||||||
|
(quantified)
|
||||||
|
] @indent
|
||||||
|
|
||||||
|
[
|
||||||
|
(variable)
|
||||||
|
"("
|
||||||
|
")"
|
||||||
|
"{"
|
||||||
|
"}"
|
||||||
|
"["
|
||||||
|
"]"
|
||||||
|
] @branch
|
||||||
|
|
||||||
|
[
|
||||||
|
(block_comment)
|
||||||
|
(line_comment)
|
||||||
|
(qldoc)
|
||||||
|
] @ignore
|
||||||
Loading…
Add table
Add a link
Reference in a new issue