Allow newlines in when clause sequences.

This commit is contained in:
KtorZ
2023-03-30 13:49:00 +02:00
parent 5d4c95d538
commit 6a4f62d074
2 changed files with 14 additions and 7 deletions

View File

@@ -133,17 +133,28 @@ fn test_format_when() {
let src = indoc! {r#"
pub fn foo( a) {
when a is{
True -> 14
True -> {
bar()
14
}
False ->
42}
42
}
}
"#};
let expected = indoc! {r#"
pub fn foo(a) {
when a is {
True ->
True -> {
bar()
14
}
False ->
42
}