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

Check that patterns bind the same variables #1403

Closed
mtzguido opened this issue Mar 13, 2018 · 1 comment
Closed

Check that patterns bind the same variables #1403

mtzguido opened this issue Mar 13, 2018 · 1 comment

Comments

@mtzguido
Copy link
Member

Not a big deal, but the following code

let f o =
    match o with
    | (Some x, _)
    | (x, Some y) -> y
    | _ -> false

fails with

A.fst(6,21-6,22): (Error 230) Variable "y#6" not found

which is confusing if the match is a big one. Somewhat related to #1121.

@A-Manning
Copy link
Contributor

Fixed in #1404

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants