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(Combinatorics/Enumerative/Partition): auto-derive DecidableEq #20277

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions Mathlib/Combinatorics/Enumerative/Partition.lean
Original file line number Diff line number Diff line change
Expand Up @@ -54,12 +54,11 @@ structure Partition (n : ℕ) where
parts_pos : ∀ {i}, i ∈ parts → 0 < i
/-- proof that the `parts` sum to `n`-/
parts_sum : parts.sum = n
-- Porting note: chokes on `parts_pos`
--deriving DecidableEq
deriving DecidableEq

namespace Partition

-- TODO: This should be automatically derived, see https://github.com/leanprover/lean4/issues/2914
@[deprecated "Partition now derives an instance of DecidableEq." (since := "2024-12-28")]
instance decidableEqPartition {n : ℕ} : DecidableEq (Partition n) :=
fun _ _ => decidable_of_iff' _ Partition.ext_iff

Expand Down
Loading