Erase functions to fun#3661
Open
gebner wants to merge 5 commits into
Open
Conversation
Contributor
Author
|
Check-world found two interesting regressions:
|
Contributor
|
I guess I am the Inria folk who like to treat warning as errors (sorry!), I can disable some more warnings if needed. I am doing this mainly because I was annoyed by the many warnings that shouldn't be warnings (e.g. #2705), but also because I think it's best practice (e.g. to ensure we don't have the proof splitting warning sprinkled throughout the project) |
Contributor
Author
|
Sorry, that wasn't meant negatively at all! The F* library has lots of warnings too, and I agree it would be nicer to avoid them in the first place. |
Contributor
|
No worries, didn't take that negatively! |
gebner
force-pushed
the
gebner_erase_fun
branch
3 times, most recently
from
January 16, 2025 02:40
f23305a to
9a3867d
Compare
gebner
force-pushed
the
gebner_erase_fun
branch
from
February 14, 2025 22:07
9a3867d to
2e971c2
Compare
gebner
force-pushed
the
gebner_erase_fun
branch
from
February 26, 2025 01:23
2e971c2 to
2d9c881
Compare
gebner
force-pushed
the
gebner_erase_fun
branch
from
March 26, 2025 16:42
2d9c881 to
24b858b
Compare
This only works if extraction can see through the type definitions, in general this requires `--cmi`. Fixes #3366
Contributor
Author
|
Check-world only reports two regressions now:
|
Contributor
Author
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.
Currently all erasable terms are erased to unit. This changes the
non_informativefunction to return anoption terminstead ofbool. This optional term specifies what the type should be erased to. For example,non_informative `(unit -> prop)returnsSome `(fun _ -> ()).There are no user-facing changes, you still write
[@@erasable] val foo ...as before. This PR also makes themust_erase_for_extractionattribute a (deprecated) alias oferasable.Fixes #3366. (only when
--cmiis enabled, but we're planning to make that the default anyhow)