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

[Merged by Bors] - feat(*): several @[simp] lemmas #2579

Closed
wants to merge 6 commits into from
Closed

Conversation

urkud
Copy link
Member

@urkud urkud commented May 1, 2020

Also add an explicit instance for submodule.has_coe_to_sort.
This way rintro ⟨x, hx⟩ results in (hx : x ∈ p).

Also fixes some timeouts introduced by #2363. See Zulip: https://leanprover.zulipchat.com/#narrow/stream/113488-general/topic/partrec_code

Also add an explicit instance for `submodule.has_coe_to_sort`.
This way `rintro ⟨x, hx⟩` results in `(hx : x ∈ p)`.
Copy link
Member

@jcommelin jcommelin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

bors merge

@@ -584,6 +584,14 @@ by simp [and_comm]
@[simp] theorem exists_eq_right {a' : α} : (∃ a, p a ∧ a = a') ↔ p a' :=
(exists_congr $ by exact λ a, and.comm).trans exists_eq_left

@[simp] theorem exists_exists_and_eq_and {f : α → β} {p : α → Prop} {q : β → Prop} :
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can imagine that there are 37 permutations of these lemmas, but maybe these two are the only ones that typically show up in a "simp-path"...

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These two come from ∃ y ∈ f '' s and ∃ y ∈ set.range f.

@github-actions github-actions bot added the ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) label May 1, 2020
bors bot pushed a commit that referenced this pull request May 1, 2020
Also add an explicit instance for `submodule.has_coe_to_sort`.
This way `rintro ⟨x, hx⟩` results in `(hx : x ∈ p)`.
@bors
Copy link

bors bot commented May 1, 2020

Build failed:

@urkud urkud removed the ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) label May 1, 2020
@urkud
Copy link
Member Author

urkud commented May 1, 2020

bors r-

@urkud
Copy link
Member Author

urkud commented May 1, 2020

Build fails because of mid-proof simps simplify more than expected.

Comment on lines +485 to +486
| left := ↑(λ n : ℕ, n.unpair.1)
| right := ↑(λ n : ℕ, n.unpair.2)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

@urkud urkud May 1, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you have an idea why this became an issue after #2363? It was ~1s before and ~70s after.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unfortunately, no. Have you looked at type class search traces before and after?

@urkud urkud added the awaiting-review The author would like community review of the PR label May 1, 2020
@sgouezel
Copy link
Collaborator

sgouezel commented May 2, 2020

bors r+

@github-actions github-actions bot added ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.) and removed awaiting-review The author would like community review of the PR labels May 2, 2020
bors bot pushed a commit that referenced this pull request May 2, 2020
Also add an explicit instance for `submodule.has_coe_to_sort`.
This way `rintro ⟨x, hx⟩` results in `(hx : x ∈ p)`.

Also fixes some timeouts introduced by #2363. See Zulip: https://leanprover.zulipchat.com/#narrow/stream/113488-general/topic/partrec_code
@bors
Copy link

bors bot commented May 2, 2020

Pull request successfully merged into master.

Build succeeded:

@bors bors bot changed the title feat(*): several @[simp] lemmas [Merged by Bors] - feat(*): several @[simp] lemmas May 2, 2020
@bors bors bot closed this May 2, 2020
@bors bors bot deleted the simp-lemmas branch May 2, 2020 12:33
anrddh pushed a commit to anrddh/mathlib that referenced this pull request May 15, 2020
Also add an explicit instance for `submodule.has_coe_to_sort`.
This way `rintro ⟨x, hx⟩` results in `(hx : x ∈ p)`.

Also fixes some timeouts introduced by leanprover-community#2363. See Zulip: https://leanprover.zulipchat.com/#narrow/stream/113488-general/topic/partrec_code
anrddh pushed a commit to anrddh/mathlib that referenced this pull request May 16, 2020
Also add an explicit instance for `submodule.has_coe_to_sort`.
This way `rintro ⟨x, hx⟩` results in `(hx : x ∈ p)`.

Also fixes some timeouts introduced by leanprover-community#2363. See Zulip: https://leanprover.zulipchat.com/#narrow/stream/113488-general/topic/partrec_code
cipher1024 pushed a commit to cipher1024/mathlib that referenced this pull request Mar 15, 2022
Also add an explicit instance for `submodule.has_coe_to_sort`.
This way `rintro ⟨x, hx⟩` results in `(hx : x ∈ p)`.

Also fixes some timeouts introduced by leanprover-community#2363. See Zulip: https://leanprover.zulipchat.com/#narrow/stream/113488-general/topic/partrec_code
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ready-to-merge All that is left is for bors to build and merge this PR. (Remember you need to say `bors r+`.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants