mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-03 03:56:52 -04:00
Add parser `php_only` for PHP files without HTML embedded. Make queries for combined parser `php` inherit from `php_only` (no extensions needed). --------- Co-authored-by: shirasaka <tk.shirasaka@gmail>
38 lines
575 B
Scheme
38 lines
575 B
Scheme
[
|
|
(array_creation_expression)
|
|
(compound_statement)
|
|
(declaration_list)
|
|
(binary_expression)
|
|
(return_statement)
|
|
(arguments)
|
|
(formal_parameters)
|
|
(enum_declaration_list)
|
|
(switch_block)
|
|
(match_block)
|
|
(case_statement)
|
|
] @indent.begin
|
|
|
|
[
|
|
")"
|
|
"}"
|
|
"]"
|
|
] @indent.branch
|
|
|
|
(comment) @indent.auto
|
|
|
|
(compound_statement
|
|
"}" @indent.end)
|
|
|
|
(ERROR
|
|
"(" @indent.align
|
|
.
|
|
(_)
|
|
(#set! indent.open_delimiter "(")
|
|
(#set! indent.close_delimiter ")"))
|
|
|
|
(ERROR
|
|
"[" @indent.align
|
|
.
|
|
(_)
|
|
(#set! indent.open_delimiter "[")
|
|
(#set! indent.close_delimiter "]"))
|