fix parsing issue

This commit is contained in:
Sébastien Besnier 2020-11-04 16:56:49 +01:00
parent 6db4bd6ed4
commit a6a4750501
2 changed files with 10 additions and 4 deletions

View file

@ -53,14 +53,20 @@ pub fn desugar_def<'a>(arena: &'a Bump, def: &'a Def<'a>) -> Def<'a> {
comment,
body_pattern,
body_expr,
} => AnnotatedBody {
}
| Nested(AnnotatedBody {
ann_pattern,
ann_type,
comment,
body_pattern,
body_expr,
}) => AnnotatedBody {
ann_pattern: ann_pattern,
ann_type: ann_type,
comment: *comment,
body_pattern: *body_pattern,
body_expr: desugar_expr(arena, body_expr),
},
Nested(ann_body @ AnnotatedBody { .. }) => Nested(ann_body),
Nested(NotYetImplemented(s)) => todo!("{}", s),
NotYetImplemented(s) => todo!("{}", s),
}