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

Dynamic layout for inexhaustive case/indeterminately match case #1125

Draft
wants to merge 23 commits into
base: dev
Choose a base branch
from

Conversation

pigumar1
Copy link
Contributor

No description provided.

@pigumar1 pigumar1 self-assigned this Oct 22, 2023
@pigumar1 pigumar1 marked this pull request as draft October 22, 2023 17:16
@@ -271,7 +272,11 @@ let rec dhexp_of_uexp =
| InHole(
InexhaustiveMatch(Some(Common(Inconsistent(Internal(_))))),
) =>
// TODO: review
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not problematic for now since currently DHExp.InexhaustiveCase behaves exactly the same as DHExp.InconsistentBranches

@cyrus- cyrus- marked this pull request as ready for review November 10, 2023 05:38
Copy link
Member

@cyrus- cyrus- left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see comment -- I think we can unify the case constructs here rather than implementing a third variant

@@ -33,6 +33,7 @@ module rec DHExp: {
| Prj(t, int)
| Constructor(string)
| ConsistentCase(case)
| InexhaustiveCase(MetaVar.t, HoleInstanceId.t, case)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of having three different case constructs in DHExp, let's merge them into one with an additional flag parameter for when there is an error.

@cyrus- cyrus- added the needs-polish for PRs that are substantially complete but need final polish label Nov 18, 2023
@cyrus- cyrus- marked this pull request as draft November 18, 2023 20:37
Base automatically changed from haz3l-case-redundancy to haz3l-case-exhaustiveness February 13, 2024 17:58
Base automatically changed from haz3l-case-exhaustiveness to dev May 19, 2024 23:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs-polish for PRs that are substantially complete but need final polish
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants