helix-mods/runtime/queries/rust/indents.toml
Blaž Hrastnik 4a9d1163e0 Hacky way to specify indent scopes per language via toml configs.
Can't do it via a scm query nicely because it returns an iterator over
all the matches, whereas we want to traverse the tree ourselves.

Can't extract the pattern data from a parsed query either.

Oh well, toml files for now.
2021-05-14 19:21:46 +09:00

30 lines
458 B
TOML

indent = [
"while_expression",
"for_expression",
"loop_expression",
"if_expression",
"if_let_expression",
"tuple_expression",
"array_expression",
"use_list",
"block",
"match_block",
"arguments",
"parameters",
"declaration_list",
"field_declaration_list",
"field_initializer_list",
"struct_pattern",
"tuple_pattern",
"enum_variant_list",
"binary_expression",
"field_expression",
"where_clause"
]
outdent = [
"where",
"}",
"]",
")"
]