[Merged by Bors] - fix: re-port Init/Algebra/Order#4000
Closed
eric-wieser wants to merge 20 commits intomasterfrom
Closed
[Merged by Bors] - fix: re-port Init/Algebra/Order#4000eric-wieser wants to merge 20 commits intomasterfrom
eric-wieser wants to merge 20 commits intomasterfrom
Conversation
cfbb1a6 to
d563d3d
Compare
The original port was missing a handful of `#align`s
d563d3d to
c9b21a3
Compare
eric-wieser
commented
May 15, 2023
Mathlib/Init/Algebra/Order.lean
Outdated
Comment on lines
+136
to
+172
| instance decidableLT_of_decidableLE [DecidableRel (. ≤ . : α → α → Prop)] : | ||
| DecidableRel (. < . : α → α → Prop) | ||
| | a, b => | ||
| if hab : a ≤ b then | ||
| if hba : b ≤ a then | ||
| isFalse $ λ hab' => not_le_of_gt hab' hba | ||
| else | ||
| isTrue $ lt_of_le_not_le hab hba | ||
| else | ||
| isFalse $ λ hab' => hab (le_of_lt hab') | ||
| /-- `<` is decidable if `≤` is. -/ | ||
| def decidableLTOfDecidableLE [@DecidableRel α (· ≤ ·)] : @DecidableRel α (· < ·) | ||
| | a, b => | ||
| if hab : a ≤ b then | ||
| if hba : b ≤ a then isFalse fun hab' => not_le_of_gt hab' hba | ||
| else isTrue <| lt_of_le_not_le hab hba | ||
| else isFalse fun hab' => hab (le_of_lt hab') | ||
| #align decidable_lt_of_decidable_le decidableLTOfDecidableLE |
Member
Author
There was a problem hiding this comment.
This should not have been an instance
This renames * `decidable_eq` to `deciableEq` * `decidable_lt` to `deciableLT` * `decidable_le` to `deciableLE` * `decidableLT_of_decidableLE` to `decidableLTOfDecidableLE` * `decidableEq_of_decidableLE` to `decidableEqOfDecidableLE`
1 task
Contributor
|
This PR/issue depends on:
|
Contributor
|
bors merge |
bors bot
pushed a commit
that referenced
this pull request
May 16, 2023
The ad-hoc port was added in #18, but the `#align`s were all missing and two defs were incorrectly promoted to an instance. The absense of these instances reveals some missing instances that need to be added (and were found via unfolding in Lean 3).
bors bot
pushed a commit
that referenced
this pull request
May 16, 2023
The ad-hoc port was added in #18, but the `#align`s were all missing and two defs were incorrectly promoted to an instance. The absense of these instances reveals some missing instances that need to be added (and were found via unfolding in Lean 3).
|
Pull request successfully merged into master. Build succeeded! The publicly hosted instance of bors-ng is deprecated and will go away soon. If you want to self-host your own instance, instructions are here. If you want to switch to GitHub's built-in merge queue, visit their help page. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The ad-hoc port was added in #18, but the
#aligns were all missing and two defs were incorrectly promoted to an instance.The absense of these instances reveals some missing instances that need to be added (and were found via unfolding in Lean 3).
LinearOrderdecidable fields #4006This is needed to faithfully forward-port leanprover-community/mathlib3#18848.
I've removed @denayd from the author list, since the original code was discarded in favor of the mathport output.