diff options
author | Blaž Hrastnik | 2021-05-09 10:02:35 +0000 |
---|---|---|
committer | Blaž Hrastnik | 2021-05-09 10:02:35 +0000 |
commit | 5954dafdbc8213ff7a84349418d15d293fcdcd4c (patch) | |
tree | f3041a1d56282d54d8004561764cdfc7036a4f96 /helix-core | |
parent | ccdebb99b547cd2eafc0b0e4f5cfc116fa729487 (diff) |
Indent array and tuple lists too.
Diffstat (limited to 'helix-core')
-rw-r--r-- | helix-core/src/indent.rs | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/helix-core/src/indent.rs b/helix-core/src/indent.rs index d0a0e414..23b21ed3 100644 --- a/helix-core/src/indent.rs +++ b/helix-core/src/indent.rs @@ -55,7 +55,8 @@ fn calculate_indentation(node: Option<Node>, newline: bool) -> usize { "if_let_expression", // "match_expression", // "match_arm", - + "tuple_expression", + "array_expression", // indent_except_first_scopes "use_list", "block", @@ -253,6 +254,15 @@ pub fn change<I>(document: &Document, changes: I) -> Self where I: IntoIterator<Item = Change> + ExactSizeIterator, { + [ + 1, + 2, + 3, + ]; + ( + 1, + 2 + ); true } ", |