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 a conference tutorial #299

Merged
merged 46 commits into from
Aug 19, 2024
Merged

Add a conference tutorial #299

merged 46 commits into from
Aug 19, 2024

Conversation

sonmarcho
Copy link
Member

@sonmarcho sonmarcho commented Aug 14, 2024

This PR adds a tutorial for Lean which can be used for workshops/conferences.

It also introduces many improvements (for the Lean backend):

  • progress now automatically splits the conjuncts in the post-conditions (no need for the .. in progress as ⟨ x .. ⟩ anymore). It also uses a smart version of assumption which applies an assumption to a goal containing meta-variables only if there is a single matching assumption in the context (this way, we avoid spurious instantiations of meta-variables, while benefiting from a good level of automation).
  • it fixes issues with scalar_tac, including performance issues, problems with the preprocessing which would not simplify the context as much as expected, better handling of natural numbers, more preprocessing to handle disjunctions, etc.
  • it introduces Scalar.toNat, U32.toNat, etc.
  • it introduces delaborators for the scalars. For instance, before we had the notation 1#u32 which desugared to U32.ofInt 1 (by scalar_tac). Until now it was however printed as U32.ofInt 1 ... in the goals. It now gets printed to 1#u32.
  • definitions for overflow_add, ! (for scalars), Vec::resize
  • it fixes type checking issues by marking the extracted trait implementations as reducible
  • it introduces scalar_nf and scalar_eq_nf (which use ring_nf)
  • it introduces dcases, a modified version of cases which allows to perform case disjunction about decidable propositions in a simpler manner

If there are meta-variables in a precondition, progress will apply an assumption
(which instantiates the meta-variables) only if there is a unique assumption
matching the precondition.
@sonmarcho sonmarcho marked this pull request as ready for review August 19, 2024 11:39
@sonmarcho sonmarcho merged commit b1ca1ff into main Aug 19, 2024
10 checks passed
@sonmarcho sonmarcho deleted the son/tutorial branch August 19, 2024 15:03
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