implement mono / lowering for tuples

This commit is contained in:
Joshua Warner 2023-01-24 20:23:17 -08:00
parent 65f8bb3d0d
commit 5a6be05ead
No known key found for this signature in database
GPG key ID: 89AD497003F93FDD
42 changed files with 1773 additions and 290 deletions

View file

@ -1872,9 +1872,8 @@ fn expr_to_pattern_help<'a>(arena: &'a Bump, expr: &Expr<'a>) -> Result<Pattern<
is_negative: *is_negative,
}),
// These would not have parsed as patterns
Expr::RecordAccessorFunction(_)
Expr::AccessorFunction(_)
| Expr::RecordAccess(_, _)
| Expr::TupleAccessorFunction(_)
| Expr::TupleAccess(_, _)
| Expr::List { .. }
| Expr::Closure(_, _)
@ -2459,8 +2458,7 @@ fn ident_to_expr<'a>(arena: &'a Bump, src: Ident<'a>) -> Expr<'a> {
answer
}
Ident::RecordAccessorFunction(string) => Expr::RecordAccessorFunction(string),
Ident::TupleAccessorFunction(string) => Expr::TupleAccessorFunction(string),
Ident::AccessorFunction(string) => Expr::AccessorFunction(string),
Ident::Malformed(string, problem) => Expr::MalformedIdent(string, problem),
}
}