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

(deep) disjunctive patterns in backend that don't support them (e.g. F*) #463

Closed
Tracked by #806
W95Psp opened this issue Jan 29, 2024 · 0 comments · Fixed by #830
Closed
Tracked by #806

(deep) disjunctive patterns in backend that don't support them (e.g. F*) #463

W95Psp opened this issue Jan 29, 2024 · 0 comments · Fixed by #830
Assignees

Comments

@W95Psp
Copy link
Collaborator

W95Psp commented Jan 29, 2024

@franziskuskiefer wrote in #462

Disjunctive patterns aren't supported in the F* backend. They are supported since #306.

There is a test in https://github.com/hacspec/hax/blob/main/tests/pattern-or/src/lib.rs

This issue covers the case "deep" disjunctive patterns, eg:

fn f(x: &[u8]) -> u8 {
    match x {
        [] => 0,
        [(1|2|3),..] => 1,
        _ => 2
    }
}

Roadmap

F* doesn't support such patterns, we need a phase that will turn such such a match into multiple nested ones.

@W95Psp W95Psp self-assigned this Jan 29, 2024
@W95Psp W95Psp changed the title Support (deep) disjunctive patterns in F* (deep) disjunctive patterns in backend that don't support them (e.g. F*) Jan 29, 2024
@github-project-automation github-project-automation bot moved this to Done in hax Aug 8, 2024
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

Successfully merging a pull request may close this issue.

1 participant