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

refactor: IndPredBelow: use apply_assumption #4841

Open
wants to merge 2 commits into from

Conversation

nomeata
Copy link
Contributor

@nomeata nomeata commented Jul 26, 2024

when transforming the match statements in IndPredBelow, given a
local variable x : T, we need to search for hx : T.below x.
Previously this was done using the custom backwardsChaining method,
although my hypothesis is that we don’t need to chain anything here, and
can use apply_assumption.

when transforming the `match` statements in `IndPredBelow`, given a
local variable `x : T`, we need to search for `hx : T.below x`.
Previously this was done using the custom `backwardsChaining` method,
although my hypothesis is that we don’t need to chain anything here, and
can use `apply_assumption`.
@github-actions github-actions bot temporarily deployed to lean-lang.org/lean4/doc July 26, 2024 10:14 Inactive
@github-actions github-actions bot added the toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN label Jul 26, 2024
@leanprover-community-mathlib4-bot
Copy link
Collaborator

leanprover-community-mathlib4-bot commented Jul 26, 2024

Mathlib CI status (docs):

  • ❗ Batteries CI can not be attempted yet, as the nightly-testing-2024-07-26 tag does not exist there yet. We will retry when you push more commits. If you rebase your branch onto nightly-with-mathlib, Batteries CI should run now. (2024-07-26 10:25:39)
  • ✅ Mathlib branch lean-pr-testing-4841 has successfully built against this PR. (2024-07-27 16:18:31) View Log

leanprover-community-mathlib4-bot added a commit to leanprover-community/batteries that referenced this pull request Jul 27, 2024
leanprover-community-mathlib4-bot added a commit to leanprover-community/mathlib4 that referenced this pull request Jul 27, 2024
@github-actions github-actions bot temporarily deployed to lean-lang.org/lean4/doc July 27, 2024 15:15 Inactive
@leanprover-community-mathlib4-bot leanprover-community-mathlib4-bot added the builds-mathlib CI has verified that Mathlib builds against this PR label Jul 27, 2024
@nomeata
Copy link
Contributor Author

nomeata commented Jul 28, 2024

@DanielFabian. Here too: It seems that backwards chaining is more powerful than we need here. WDYT of this change, to make it more clear that we don’t expect recursive search here? Or would you suggest to not change this code without a clear need at this point?

@nomeata nomeata marked this pull request as ready for review July 28, 2024 15:21
@DanielFabian
Copy link
Contributor

I'm all for simplifying and even deleting backwards chaining if we can get rid of it. I built it initially because in those days the automation features were not quite there yet and it was an easy enough tactic to build. But I'm in no way attached to it. We have our motivating examples in the unit tests, imo.

@nomeata nomeata added this pull request to the merge queue Jul 28, 2024
Any commits made after this event will not be merged.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
builds-mathlib CI has verified that Mathlib builds against this PR toolchain-available A toolchain is available for this PR, at leanprover/lean4-pr-releases:pr-release-NNNN
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants