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

Only check for escaped skolem variables among those just generated #2104

Merged
merged 1 commit into from
Aug 9, 2024

Conversation

byorgey
Copy link
Member

@byorgey byorgey commented Aug 9, 2024

Fixes #2101.

  • Modifies skolemize to return the list of generated variable names along with the substituted type (and remove an unnecessary call to error!)
  • Then in noSkolems only check for relevant, recently-generated skolem variables instead of for any skolem variables at all.

@byorgey byorgey requested a review from xsebek August 9, 2024 17:08
, testCase
"nested polymorphic def/annot"
(valid "def id : a -> a * Int = \\y. (y, 3 : Int) end")
]
Copy link
Member Author

Choose a reason for hiding this comment

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

These minimal test cases were failing before the fix.

Copy link
Member

@xsebek xsebek left a comment

Choose a reason for hiding this comment

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

This looks reasonable to me. 👍

I am glad that the test examples here will parse, those would surprise me even more than the example I have given.

@byorgey byorgey added the merge me Trigger the merge process of the Pull request. label Aug 9, 2024
@mergify mergify bot merged commit 164acf8 into main Aug 9, 2024
12 checks passed
@mergify mergify bot deleted the fix-skolem-check branch August 9, 2024 19:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge me Trigger the merge process of the Pull request.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Strange type checking error "Skolem variable would escape its scope"
2 participants