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

chore: adapt to decide := false in simp #78

Merged
merged 1 commit into from
Oct 26, 2023

Conversation

collares
Copy link
Contributor

Future-proofing for leanprover/lean4#2722. A comment on SimpConfig is missing but I didn't exactly know what to write.

@JLimperg
Copy link
Collaborator

I'd prefer to match stock simp behaviour, i.e. keep decide := false by default. Reasons:

  • Less surprising behaviour; Aesop simp_all is really just simp_all.
  • aesop? would otherwise have to start generating simp_all (config := { decide := true }) invocations.

Does decide := false break mathlib a lot?

@collares collares force-pushed the lean-pr-testing-2722 branch 2 times, most recently from 3d1eb39 to e6d2c12 Compare October 23, 2023 17:17
@collares
Copy link
Contributor Author

@JLimperg It's easy to fix it on the mathlib side, I just mistakenly thought decide := true would be preferred in aesop. The one remaining non-comment change in this PR is needed to fix this error when decide is not used by default:

./lake-packages/aesop/././Aesop/Search/Expansion/Norm.lean:380:60: error: unsolved goals
rs : RuleSet
normSimpContext : NormSimpContext
options : Options'
goal : MVarId
mvars : UnorderedArraySet MVarId
mvarsHashSet : HashSet MVarId := HashSet.ofArray (UnorderedArraySet.toArray mvars)
normSteps : Array NormStep :=
  #[NormStep.runPreSimpRules options mvars, NormStep.unfold rs options mvarsHashSet,
    NormStep.simp rs normSimpContext options mvarsHashSet, NormStep.runPostSimpRules options mvars]
⊢ 0 < Nat.succ (Nat.succ (Nat.succ 1))

@collares collares changed the title chore: default to decide := true for simp chore: adapt to decide := false in simp Oct 23, 2023
@collares collares force-pushed the lean-pr-testing-2722 branch from e6d2c12 to 773aaa0 Compare October 26, 2023 12:44
@JLimperg
Copy link
Collaborator

Great, thanks! I'll merge when CI is green.

@JLimperg JLimperg merged commit 5e01623 into leanprover-community:master Oct 26, 2023
1 check passed
@collares collares deleted the lean-pr-testing-2722 branch November 3, 2023 08:53
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.

2 participants