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

Add an UnfoldOnce/delta_once normalizer step #3626

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

mtzguido
Copy link
Member

@mtzguido mtzguido commented Dec 6, 2024

Discussed with @nikswamy and @tahina-pro , motivated by #3616 from @TWal.

This adds a way to unfold a top-level definition, recursive or not, only 'once', avoiding any possible normalization loops. This PR also uses it for reveal_opaque, so it still works for recursive functions (after #3621) and will avoid unfolding loops. Here is the documentation for the step:

(** Like [delta_only], unfold only the definitions in this list,
but do so only once. This is useful for a controlled unfolding
of recursive definitions. NOTE: if there are many occurrences
of a variable in this list, it is unspecified which one will
be unfolded (currently it depends on normalization order). *)
val delta_once (s: list string) : Tot norm_step

Running a check here: https://github.com/mtzguido/FStar/actions/runs/12206414931

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 this pull request may close these issues.

1 participant