Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't require inversions for reverse lambdas #76

Open
TomasMikula opened this issue Feb 22, 2023 · 0 comments
Open

Don't require inversions for reverse lambdas #76

TomasMikula opened this issue Feb 22, 2023 · 0 comments
Labels
enhancement New feature or improvement of programmer experience

Comments

@TomasMikula
Copy link
Owner

The reverse lambda, i.e. producing in

 λ { (a: $[A]) =>
  producing { (b: ??[B]) =>
    // ...
  }
} : A -B

where b is a placeholder for the out-port, is currently implemented via a forward lambda on an inverted expression (??[B] = $[-[B]]).

This has 2 drawbacks:

  • It is only available if the the underlying DSL (-⚬) has inversions.
  • The resulting point-free AST contains extra inversions.

However, reverse lambdas can be implemented without inversions. Note that it will require some changes (generalizations) in the implementation of lambda translation, though.

@TomasMikula TomasMikula added the enhancement New feature or improvement of programmer experience label Feb 22, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or improvement of programmer experience
Projects
None yet
Development

No branches or pull requests

1 participant