mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-03 19:58:18 +00:00
fix formatter crash
This commit is contained in:
parent
b9d5979c1f
commit
c89c8c3e95
1 changed files with 2 additions and 1 deletions
|
@ -42,7 +42,8 @@ impl<'a> Formattable for Pattern<'a> {
|
|||
// Theory: a pattern should only be multiline when it contains a comment
|
||||
match self {
|
||||
Pattern::SpaceBefore(_, spaces) | Pattern::SpaceAfter(_, spaces) => {
|
||||
debug_assert!(!spaces.is_empty());
|
||||
//TODO: This isn't always true, should it be?
|
||||
// debug_assert!(!spaces.is_empty());
|
||||
|
||||
spaces.iter().any(|s| s.is_comment())
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue