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

GADT code in OCaml #2642

Open
EduardoRFS opened this issue Dec 8, 2020 · 0 comments
Open

GADT code in OCaml #2642

EduardoRFS opened this issue Dec 8, 2020 · 0 comments

Comments

@EduardoRFS
Copy link
Contributor

In OCaml this two pieces of code are different

let cdr = fun (Cdr, ((_, b), rest)) -> (b, rest)
let cdr (Cdr, ((_, b), rest)) = (b, rest)

The first one when you're working with GADTs say that the pattern matching is not exhaustive, the second one doesn't, but there is no good way to represent the second one in Reason

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