improved malformed patterns

This commit is contained in:
Folkert 2021-03-01 16:12:37 +01:00
parent 2ae993d695
commit a87dfac7da
10 changed files with 316 additions and 126 deletions

View file

@ -267,12 +267,15 @@ fn loc_ident_pattern_help<'a>(
},
state,
)),
Ident::Malformed(malformed, _problem) => {
Ident::Malformed(malformed, problem) => {
debug_assert!(!malformed.is_empty());
Err((
Ok((
MadeProgress,
EPattern::Start(state.line, state.column),
Located {
region: loc_ident.region,
value: Pattern::MalformedIdent(malformed, problem),
},
state,
))
}