Skip to content

Commit cc20545

Browse files
YaelDilliesRida-Hamadani
authored andcommitted
chore(FreeAbelianGroup): rename punitEquiv to uniqueEquiv (leanprover-community#25954)
This was generalised without being renamed.
1 parent 0c8705d commit cc20545

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Mathlib/GroupTheory/FreeAbelianGroup.lean

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -551,7 +551,7 @@ instance pemptyUnique : Unique (FreeAbelianGroup PEmpty) where
551551
rfl)
552552

553553
/-- The free abelian group on a type with one term is isomorphic to `ℤ`. -/
554-
def punitEquiv (T : Type*) [Unique T] : FreeAbelianGroup T ≃+ ℤ where
554+
def uniqueEquiv (T : Type*) [Unique T] : FreeAbelianGroup T ≃+ ℤ where
555555
toFun := FreeAbelianGroup.lift fun _ ↦ (1 : ℤ)
556556
invFun n := n • of Inhabited.default
557557
left_inv z := FreeAbelianGroup.induction_on z
@@ -565,6 +565,8 @@ def punitEquiv (T : Type*) [Unique T] : FreeAbelianGroup T ≃+ ℤ where
565565
exact zsmul_int_one n
566566
map_add' := AddMonoidHom.map_add _
567567

568+
@[deprecated (since := "2025-06-16")] alias punitEquiv := uniqueEquiv
569+
568570
/-- Isomorphic types have isomorphic free abelian groups. -/
569571
def equivOfEquiv {α β : Type*} (f : α ≃ β) : FreeAbelianGroup α ≃+ FreeAbelianGroup β where
570572
toFun := map f

0 commit comments

Comments
 (0)