cleanup, improve docs

This commit is contained in:
Luke Boswell 2024-04-12 15:10:16 +10:00
parent c32fa5b600
commit 0143035dc0
No known key found for this signature in database
GPG key ID: F6DB3C9DB47377B0
8 changed files with 42 additions and 60 deletions

View file

@ -128,7 +128,7 @@ pub fn unwrap_suffixed_expression<'a>(
},
));
// we generate an intermedite pattern `#!a0` etc
// we generate an intermediate pattern `#!a0` etc
// so we dont unwrap the definition pattern
let (mut answer_var, answer_pat) = next_suffixed_answer_pattern(arena);
@ -363,6 +363,9 @@ pub fn unwrap_suffixed_expression_if_then_else_help<'a>(
) -> Result<&'a Loc<Expr<'a>>, EUnwrapped<'a>> {
Ok(loc_expr)
// TODO - the logic below is mostly correct, however it needs to be
// translated to this new method and tests added, leaving this for a future PR
// consider each if-statement, if it is suffixed we need to desugar e.g.
// ```
// if isFalse! then