feat(treesitter): upstream foldexpr from nvim-treesitter

This commit is contained in:
Lewis Russell
2023-02-23 17:05:20 +00:00
committed by GitHub
parent 8c339aa04b
commit 1df3f5ec6a
8 changed files with 276 additions and 0 deletions

View File

@ -0,0 +1,19 @@
[
(for_statement)
(if_statement)
(while_statement)
(switch_statement)
(case_statement)
(function_definition)
(struct_specifier)
(enum_specifier)
(comment)
(preproc_if)
(preproc_elif)
(preproc_else)
(preproc_ifdef)
(initializer_list)
] @fold
(compound_statement
(compound_statement) @fold)

View File

@ -0,0 +1,10 @@
[
(do_statement)
(while_statement)
(repeat_statement)
(if_statement)
(for_statement)
(function_declaration)
(function_definition)
(table_constructor)
] @fold

View File

@ -0,0 +1,4 @@
[
(if_statement)
(function_definition)
] @fold