v.checker: small cleanup for incomplete match errors
parent
72c56ccc85
commit
b9771ea120
|
@ -6242,7 +6242,9 @@ fn (mut c Checker) match_exprs(mut node ast.MatchExpr, cond_type_sym ast.TypeSym
|
||||||
} else {
|
} else {
|
||||||
remaining := unhandled.len - c.match_exhaustive_cutoff_limit
|
remaining := unhandled.len - c.match_exhaustive_cutoff_limit
|
||||||
err_details += unhandled[0..c.match_exhaustive_cutoff_limit].join(', ')
|
err_details += unhandled[0..c.match_exhaustive_cutoff_limit].join(', ')
|
||||||
err_details += ', and $remaining others ...'
|
if remaining > 0 {
|
||||||
|
err_details += ', and $remaining others ...'
|
||||||
|
}
|
||||||
}
|
}
|
||||||
err_details += ' or `else {}` at the end)'
|
err_details += ' or `else {}` at the end)'
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue