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

Coherence constraints for Choose #2

Open
ebfull opened this issue Oct 23, 2015 · 0 comments
Open

Coherence constraints for Choose #2

ebfull opened this issue Oct 23, 2015 · 0 comments

Comments

@ebfull
Copy link
Owner

ebfull commented Oct 23, 2015

None of these have safety implications, but there are a number of coherence constraints ideal for Choose:

  • We don't want types like Choose<A, Choose<B, Finally<A>>> to be expressible. That is, there exists no Chooser<A, B> such that Chooser<A, B>: Chooser<S> and B: Chooser<S>.
  • We should ensure that Choose<P, Q> only allows Choose and Finally to exist as Q.
  • Finally should not exist outside of Choose, if possible.

As a bonus, it may not be necessary to use Finally at all, but I am doubtful.

@ebfull ebfull changed the title Well-formedness for Choose Coherence constraints for Choose Oct 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant