Draft
Conversation
# Conflicts: # parser-typechecker/src/Unison/Syntax/TermParser.hs
not sure why the `GiveA`/`GiveB` abilities are reversed here.
aryairani
reviewed
Jul 30, 2024
Comment on lines
+28
to
+46
| ``` unison | ||
| structural type Void = | ||
|
|
||
| test : Void -> a | ||
| test = cases | ||
| ``` | ||
|
|
||
| ``` ucm | ||
|
|
||
| Loading changes detected in scratch.u. | ||
|
|
||
| Pattern match doesn't cover all possible cases: | ||
| 4 | test = cases | ||
|
|
||
|
|
||
| Patterns not matched: | ||
| * () | ||
|
|
||
| ``` |
Contributor
There was a problem hiding this comment.
There seems to be a bug or missing special-case in TermParser.hs -> lamCase -> lamvarTerm that is introducing () here.
aryairani
reviewed
Jul 30, 2024
| ability GiveA a | ||
| ability GiveB a | ||
| result : '{e, GiveA V, GiveB V} r ->{e} r | ||
| result : '{e, GiveB V, GiveA V} r ->{e} r |
Contributor
There was a problem hiding this comment.
Not sure what's causing this, it wasn't in #5256 alone
aryairani
reviewed
Jul 30, 2024
Comment on lines
+5
to
+25
| ``` unison | ||
| structural type Void = | ||
|
|
||
| test : Void -> a | ||
| test x = match x with | ||
| ``` | ||
|
|
||
| ``` ucm | ||
|
|
||
| Loading changes detected in scratch.u. | ||
|
|
||
| I found and typechecked these definitions in scratch.u. If you | ||
| do an `add` or `update`, here's how your codebase would | ||
| change: | ||
|
|
||
| ⍟ These new definitions are ok to `add`: | ||
|
|
||
| structural type Void | ||
| test : Void -> a | ||
|
|
||
| ``` |
Contributor
There was a problem hiding this comment.
This case is fixed though.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
NOTE: currently this breaks exhaustiveness checking :'(
It should provide an exhaustiveness failure for an inhabited type with zero cases, but it doesn't.
The exhaustiveness checker code is pretty complex, so would take a bit of digging into to solve.