mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-27 13:59:08 +00:00
Don't do empty record destructure elision when the body is itself Defs
This commit is contained in:
parent
cabe67f88d
commit
89a64fed74
5 changed files with 83 additions and 0 deletions
|
@ -1039,6 +1039,7 @@ pub fn fmt_body<'a>(
|
|||
&& collection.is_empty()
|
||||
&& pattern_extracted.before.iter().all(|s| s.is_newline())
|
||||
&& pattern_extracted.after.iter().all(|s| s.is_newline())
|
||||
&& !matches!(body.extract_spaces().item, Expr::Defs(..))
|
||||
} else {
|
||||
false
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue