Merge remote-tracking branch 'origin/main' into https-packages

This commit is contained in:
Richard Feldman 2022-11-25 04:07:37 -05:00
commit bef59299a2
No known key found for this signature in database
GPG key ID: F1F21AA5B1D9E43B
11 changed files with 110 additions and 65 deletions

View file

@ -1791,7 +1791,7 @@ macro_rules! one_or_more {
move |arena, state: State<'a>, min_indent: u32| {
use bumpalo::collections::Vec;
match $parser.parse(arena, state, min_indent) {
match $parser.parse(arena, state.clone(), min_indent) {
Ok((_, first_output, next_state)) => {
let mut state = next_state;
let mut buf = Vec::with_capacity_in(1, arena);
@ -1809,14 +1809,12 @@ macro_rules! one_or_more {
return Ok((MadeProgress, buf, old_state));
}
Err((MadeProgress, fail)) => {
return Err((MadeProgress, fail, old_state));
return Err((MadeProgress, fail));
}
}
}
}
Err((progress, _, new_state)) => {
Err((progress, $to_error(new_state.pos), new_state))
}
Err((progress, _)) => Err((progress, $to_error(state.pos()))),
}
}
};