1
Fork 0

error parsing lifetime following by Sized and message + between them

detect the pattern at the general site parse_impl_ty()
this will fix #102598
This commit is contained in:
Yiming Lei 2022-10-13 10:30:33 -07:00
parent 37d7de3379
commit 419df5f4a0
4 changed files with 70 additions and 1 deletions

View file

@ -2449,7 +2449,6 @@ impl<'a> Parser<'a> {
};
let (pat, ty) = if is_name_required || this.is_named_param() {
debug!("parse_param_general parse_pat (is_name_required:{})", is_name_required);
let (pat, colon) = this.parse_fn_param_pat_colon()?;
if !colon {
let mut err = this.unexpected::<()>().unwrap_err();