order.category.SemilatMathlib.Order.Category.Semilat

This file has been ported!

Changes since the initial port

The following section lists changes to this file in mathlib3 and mathlib4 that occured after the initial port. Most recent changes are shown first. Hovering over a commit will show all commits associated with the same mathlib3 commit.

Changes in mathlib3

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(last sync)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -85,7 +85,7 @@ instance : ConcreteCategory SemilatSupCat
   forget :=
     { obj := SemilatSupCat.X
       map := fun X Y => coeFn }
-  forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
+  forget_faithful := ⟨fun X Y => DFunLike.coe_injective⟩
 
 #print SemilatSupCat.hasForgetToPartOrd /-
 instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrd
@@ -142,7 +142,7 @@ instance : ConcreteCategory SemilatInfCat
   forget :=
     { obj := SemilatInfCat.X
       map := fun X Y => coeFn }
-  forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
+  forget_faithful := ⟨fun X Y => DFunLike.coe_injective⟩
 
 #print SemilatInfCat.hasForgetToPartOrd /-
 instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrd
Diff
@@ -3,8 +3,8 @@ Copyright (c) 2022 Yaël Dillies. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
 -/
-import Mathbin.Order.Category.PartOrd
-import Mathbin.Order.Hom.Lattice
+import Order.Category.PartOrd
+import Order.Hom.Lattice
 
 #align_import order.category.Semilat from "leanprover-community/mathlib"@"d07a9c875ed7139abfde6a333b2be205c5bd404e"
 
@@ -88,19 +88,18 @@ instance : ConcreteCategory SemilatSupCat
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
 #print SemilatSupCat.hasForgetToPartOrd /-
-instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrdCat
+instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrd
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
 #align SemilatSup.has_forget_to_PartOrd SemilatSupCat.hasForgetToPartOrd
 -/
 
-#print SemilatSupCat.coe_forget_to_partOrdCat /-
+#print SemilatSupCat.coe_forget_to_partOrd /-
 @[simp]
-theorem coe_forget_to_partOrdCat (X : SemilatSupCat) :
-    ↥((forget₂ SemilatSupCat PartOrdCat).obj X) = ↥X :=
+theorem coe_forget_to_partOrd (X : SemilatSupCat) : ↥((forget₂ SemilatSupCat PartOrd).obj X) = ↥X :=
   rfl
-#align SemilatSup.coe_forget_to_PartOrd SemilatSupCat.coe_forget_to_partOrdCat
+#align SemilatSup.coe_forget_to_PartOrd SemilatSupCat.coe_forget_to_partOrd
 -/
 
 end SemilatSupCat
@@ -146,19 +145,18 @@ instance : ConcreteCategory SemilatInfCat
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
 #print SemilatInfCat.hasForgetToPartOrd /-
-instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrdCat
+instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrd
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
 #align SemilatInf.has_forget_to_PartOrd SemilatInfCat.hasForgetToPartOrd
 -/
 
-#print SemilatInfCat.coe_forget_to_partOrdCat /-
+#print SemilatInfCat.coe_forget_to_partOrd /-
 @[simp]
-theorem coe_forget_to_partOrdCat (X : SemilatInfCat) :
-    ↥((forget₂ SemilatInfCat PartOrdCat).obj X) = ↥X :=
+theorem coe_forget_to_partOrd (X : SemilatInfCat) : ↥((forget₂ SemilatInfCat PartOrd).obj X) = ↥X :=
   rfl
-#align SemilatInf.coe_forget_to_PartOrd SemilatInfCat.coe_forget_to_partOrdCat
+#align SemilatInf.coe_forget_to_PartOrd SemilatInfCat.coe_forget_to_partOrd
 -/
 
 end SemilatInfCat
@@ -229,19 +227,19 @@ def SemilatSupCatEquivSemilatInfCat : SemilatSupCat ≌ SemilatInfCat :=
 #align SemilatSup_equiv_SemilatInf SemilatSupCatEquivSemilatInfCat
 -/
 
-#print SemilatSupCat_dual_comp_forget_to_partOrdCat /-
-theorem SemilatSupCat_dual_comp_forget_to_partOrdCat :
-    SemilatSupCat.dual ⋙ forget₂ SemilatInfCat PartOrdCat =
-      forget₂ SemilatSupCat PartOrdCat ⋙ PartOrdCat.dual :=
+#print SemilatSupCat_dual_comp_forget_to_partOrd /-
+theorem SemilatSupCat_dual_comp_forget_to_partOrd :
+    SemilatSupCat.dual ⋙ forget₂ SemilatInfCat PartOrd =
+      forget₂ SemilatSupCat PartOrd ⋙ PartOrd.dual :=
   rfl
-#align SemilatSup_dual_comp_forget_to_PartOrd SemilatSupCat_dual_comp_forget_to_partOrdCat
+#align SemilatSup_dual_comp_forget_to_PartOrd SemilatSupCat_dual_comp_forget_to_partOrd
 -/
 
-#print SemilatInfCat_dual_comp_forget_to_partOrdCat /-
-theorem SemilatInfCat_dual_comp_forget_to_partOrdCat :
-    SemilatInfCat.dual ⋙ forget₂ SemilatSupCat PartOrdCat =
-      forget₂ SemilatInfCat PartOrdCat ⋙ PartOrdCat.dual :=
+#print SemilatInfCat_dual_comp_forget_to_partOrd /-
+theorem SemilatInfCat_dual_comp_forget_to_partOrd :
+    SemilatInfCat.dual ⋙ forget₂ SemilatSupCat PartOrd =
+      forget₂ SemilatInfCat PartOrd ⋙ PartOrd.dual :=
   rfl
-#align SemilatInf_dual_comp_forget_to_PartOrd SemilatInfCat_dual_comp_forget_to_partOrdCat
+#align SemilatInf_dual_comp_forget_to_PartOrd SemilatInfCat_dual_comp_forget_to_partOrd
 -/
 
Diff
@@ -2,15 +2,12 @@
 Copyright (c) 2022 Yaël Dillies. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
-
-! This file was ported from Lean 3 source module order.category.Semilat
-! leanprover-community/mathlib commit d07a9c875ed7139abfde6a333b2be205c5bd404e
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Order.Category.PartOrd
 import Mathbin.Order.Hom.Lattice
 
+#align_import order.category.Semilat from "leanprover-community/mathlib"@"d07a9c875ed7139abfde6a333b2be205c5bd404e"
+
 /-!
 # The categories of semilattices
 
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
 
 ! This file was ported from Lean 3 source module order.category.Semilat
-! leanprover-community/mathlib commit e8ac6315bcfcbaf2d19a046719c3b553206dac75
+! leanprover-community/mathlib commit d07a9c875ed7139abfde6a333b2be205c5bd404e
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -14,6 +14,9 @@ import Mathbin.Order.Hom.Lattice
 /-!
 # The categories of semilattices
 
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
 This defines `SemilatSup` and `SemilatInf`, the categories of sup-semilattices with a bottom
 element and inf-semilattices with a top element.
 
Diff
@@ -87,17 +87,21 @@ instance : ConcreteCategory SemilatSupCat
       map := fun X Y => coeFn }
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
+#print SemilatSupCat.hasForgetToPartOrd /-
 instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrdCat
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
 #align SemilatSup.has_forget_to_PartOrd SemilatSupCat.hasForgetToPartOrd
+-/
 
+#print SemilatSupCat.coe_forget_to_partOrdCat /-
 @[simp]
 theorem coe_forget_to_partOrdCat (X : SemilatSupCat) :
     ↥((forget₂ SemilatSupCat PartOrdCat).obj X) = ↥X :=
   rfl
 #align SemilatSup.coe_forget_to_PartOrd SemilatSupCat.coe_forget_to_partOrdCat
+-/
 
 end SemilatSupCat
 
@@ -141,17 +145,21 @@ instance : ConcreteCategory SemilatInfCat
       map := fun X Y => coeFn }
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
+#print SemilatInfCat.hasForgetToPartOrd /-
 instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrdCat
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
 #align SemilatInf.has_forget_to_PartOrd SemilatInfCat.hasForgetToPartOrd
+-/
 
+#print SemilatInfCat.coe_forget_to_partOrdCat /-
 @[simp]
 theorem coe_forget_to_partOrdCat (X : SemilatInfCat) :
     ↥((forget₂ SemilatInfCat PartOrdCat).obj X) = ↥X :=
   rfl
 #align SemilatInf.coe_forget_to_PartOrd SemilatInfCat.coe_forget_to_partOrdCat
+-/
 
 end SemilatInfCat
 
@@ -160,6 +168,7 @@ end SemilatInfCat
 
 namespace SemilatSupCat
 
+#print SemilatSupCat.Iso.mk /-
 /-- Constructs an isomorphism of lattices from an order isomorphism between them. -/
 @[simps]
 def Iso.mk {α β : SemilatSupCat.{u}} (e : α ≃o β) : α ≅ β
@@ -169,7 +178,9 @@ def Iso.mk {α β : SemilatSupCat.{u}} (e : α ≃o β) : α ≅ β
   hom_inv_id' := by ext; exact e.symm_apply_apply _
   inv_hom_id' := by ext; exact e.apply_symm_apply _
 #align SemilatSup.iso.mk SemilatSupCat.Iso.mk
+-/
 
+#print SemilatSupCat.dual /-
 /-- `order_dual` as a functor. -/
 @[simps]
 def dual : SemilatSupCat ⥤ SemilatInfCat
@@ -177,11 +188,13 @@ def dual : SemilatSupCat ⥤ SemilatInfCat
   obj X := SemilatInfCat.of Xᵒᵈ
   map X Y := SupBotHom.dual
 #align SemilatSup.dual SemilatSupCat.dual
+-/
 
 end SemilatSupCat
 
 namespace SemilatInfCat
 
+#print SemilatInfCat.Iso.mk /-
 /-- Constructs an isomorphism of lattices from an order isomorphism between them. -/
 @[simps]
 def Iso.mk {α β : SemilatInfCat.{u}} (e : α ≃o β) : α ≅ β
@@ -191,7 +204,9 @@ def Iso.mk {α β : SemilatInfCat.{u}} (e : α ≃o β) : α ≅ β
   hom_inv_id' := by ext; exact e.symm_apply_apply _
   inv_hom_id' := by ext; exact e.apply_symm_apply _
 #align SemilatInf.iso.mk SemilatInfCat.Iso.mk
+-/
 
+#print SemilatInfCat.dual /-
 /-- `order_dual` as a functor. -/
 @[simps]
 def dual : SemilatInfCat ⥤ SemilatSupCat
@@ -199,9 +214,11 @@ def dual : SemilatInfCat ⥤ SemilatSupCat
   obj X := SemilatSupCat.of Xᵒᵈ
   map X Y := InfTopHom.dual
 #align SemilatInf.dual SemilatInfCat.dual
+-/
 
 end SemilatInfCat
 
+#print SemilatSupCatEquivSemilatInfCat /-
 /-- The equivalence between `SemilatSup` and `SemilatInf` induced by `order_dual` both ways.
 -/
 @[simps Functor inverse]
@@ -210,16 +227,21 @@ def SemilatSupCatEquivSemilatInfCat : SemilatSupCat ≌ SemilatInfCat :=
     (NatIso.ofComponents (fun X => SemilatSupCat.Iso.mk <| OrderIso.dualDual X) fun X Y f => rfl)
     (NatIso.ofComponents (fun X => SemilatInfCat.Iso.mk <| OrderIso.dualDual X) fun X Y f => rfl)
 #align SemilatSup_equiv_SemilatInf SemilatSupCatEquivSemilatInfCat
+-/
 
+#print SemilatSupCat_dual_comp_forget_to_partOrdCat /-
 theorem SemilatSupCat_dual_comp_forget_to_partOrdCat :
     SemilatSupCat.dual ⋙ forget₂ SemilatInfCat PartOrdCat =
       forget₂ SemilatSupCat PartOrdCat ⋙ PartOrdCat.dual :=
   rfl
 #align SemilatSup_dual_comp_forget_to_PartOrd SemilatSupCat_dual_comp_forget_to_partOrdCat
+-/
 
+#print SemilatInfCat_dual_comp_forget_to_partOrdCat /-
 theorem SemilatInfCat_dual_comp_forget_to_partOrdCat :
     SemilatInfCat.dual ⋙ forget₂ SemilatSupCat PartOrdCat =
       forget₂ SemilatInfCat PartOrdCat ⋙ PartOrdCat.dual :=
   rfl
 #align SemilatInf_dual_comp_forget_to_PartOrd SemilatInfCat_dual_comp_forget_to_partOrdCat
+-/
 
Diff
@@ -27,43 +27,51 @@ universe u
 
 open CategoryTheory
 
+#print SemilatSupCat /-
 /-- The category of sup-semilattices with a bottom element. -/
-structure SemilatSup : Type (u + 1) where
+structure SemilatSupCat : Type (u + 1) where
   pt : Type u
   [isSemilatticeSup : SemilatticeSup X]
   [isOrderBot : OrderBot X]
-#align SemilatSup SemilatSup
+#align SemilatSup SemilatSupCat
+-/
 
+#print SemilatInfCat /-
 /-- The category of inf-semilattices with a top element. -/
-structure SemilatInf : Type (u + 1) where
+structure SemilatInfCat : Type (u + 1) where
   pt : Type u
   [isSemilatticeInf : SemilatticeInf X]
   [isOrderTop : OrderTop X]
-#align SemilatInf SemilatInf
+#align SemilatInf SemilatInfCat
+-/
 
-attribute [protected] SemilatSup.X SemilatInf.X
+attribute [protected] SemilatSupCat.X SemilatInfCat.X
 
-namespace SemilatSup
+namespace SemilatSupCat
 
-instance : CoeSort SemilatSup (Type _) :=
-  ⟨SemilatSup.X⟩
+instance : CoeSort SemilatSupCat (Type _) :=
+  ⟨SemilatSupCat.X⟩
 
 attribute [instance] is_semilattice_sup is_order_bot
 
+#print SemilatSupCat.of /-
 /-- Construct a bundled `SemilatSup` from a `semilattice_sup`. -/
-def of (α : Type _) [SemilatticeSup α] [OrderBot α] : SemilatSup :=
+def of (α : Type _) [SemilatticeSup α] [OrderBot α] : SemilatSupCat :=
   ⟨α⟩
-#align SemilatSup.of SemilatSup.of
+#align SemilatSup.of SemilatSupCat.of
+-/
 
+#print SemilatSupCat.coe_of /-
 @[simp]
 theorem coe_of (α : Type _) [SemilatticeSup α] [OrderBot α] : ↥(of α) = α :=
   rfl
-#align SemilatSup.coe_of SemilatSup.coe_of
+#align SemilatSup.coe_of SemilatSupCat.coe_of
+-/
 
-instance : Inhabited SemilatSup :=
+instance : Inhabited SemilatSupCat :=
   ⟨of PUnit⟩
 
-instance : LargeCategory.{u} SemilatSup
+instance : LargeCategory.{u} SemilatSupCat
     where
   Hom X Y := SupBotHom X Y
   id X := SupBotHom.id X
@@ -72,47 +80,52 @@ instance : LargeCategory.{u} SemilatSup
   comp_id' X Y := SupBotHom.id_comp
   assoc' W X Y Z _ _ _ := SupBotHom.comp_assoc _ _ _
 
-instance : ConcreteCategory SemilatSup
+instance : ConcreteCategory SemilatSupCat
     where
   forget :=
-    { obj := SemilatSup.X
+    { obj := SemilatSupCat.X
       map := fun X Y => coeFn }
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
-instance hasForgetToPartOrd : HasForget₂ SemilatSup PartOrdCat
+instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrdCat
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
-#align SemilatSup.has_forget_to_PartOrd SemilatSup.hasForgetToPartOrd
+#align SemilatSup.has_forget_to_PartOrd SemilatSupCat.hasForgetToPartOrd
 
 @[simp]
-theorem coe_forget_to_partOrdCat (X : SemilatSup) : ↥((forget₂ SemilatSup PartOrdCat).obj X) = ↥X :=
+theorem coe_forget_to_partOrdCat (X : SemilatSupCat) :
+    ↥((forget₂ SemilatSupCat PartOrdCat).obj X) = ↥X :=
   rfl
-#align SemilatSup.coe_forget_to_PartOrd SemilatSup.coe_forget_to_partOrdCat
+#align SemilatSup.coe_forget_to_PartOrd SemilatSupCat.coe_forget_to_partOrdCat
 
-end SemilatSup
+end SemilatSupCat
 
-namespace SemilatInf
+namespace SemilatInfCat
 
-instance : CoeSort SemilatInf (Type _) :=
-  ⟨SemilatInf.X⟩
+instance : CoeSort SemilatInfCat (Type _) :=
+  ⟨SemilatInfCat.X⟩
 
 attribute [instance] is_semilattice_inf is_order_top
 
+#print SemilatInfCat.of /-
 /-- Construct a bundled `SemilatInf` from a `semilattice_inf`. -/
-def of (α : Type _) [SemilatticeInf α] [OrderTop α] : SemilatInf :=
+def of (α : Type _) [SemilatticeInf α] [OrderTop α] : SemilatInfCat :=
   ⟨α⟩
-#align SemilatInf.of SemilatInf.of
+#align SemilatInf.of SemilatInfCat.of
+-/
 
+#print SemilatInfCat.coe_of /-
 @[simp]
 theorem coe_of (α : Type _) [SemilatticeInf α] [OrderTop α] : ↥(of α) = α :=
   rfl
-#align SemilatInf.coe_of SemilatInf.coe_of
+#align SemilatInf.coe_of SemilatInfCat.coe_of
+-/
 
-instance : Inhabited SemilatInf :=
+instance : Inhabited SemilatInfCat :=
   ⟨of PUnit⟩
 
-instance : LargeCategory.{u} SemilatInf
+instance : LargeCategory.{u} SemilatInfCat
     where
   Hom X Y := InfTopHom X Y
   id X := InfTopHom.id X
@@ -121,91 +134,92 @@ instance : LargeCategory.{u} SemilatInf
   comp_id' X Y := InfTopHom.id_comp
   assoc' W X Y Z _ _ _ := InfTopHom.comp_assoc _ _ _
 
-instance : ConcreteCategory SemilatInf
+instance : ConcreteCategory SemilatInfCat
     where
   forget :=
-    { obj := SemilatInf.X
+    { obj := SemilatInfCat.X
       map := fun X Y => coeFn }
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
-instance hasForgetToPartOrd : HasForget₂ SemilatInf PartOrdCat
+instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrdCat
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
-#align SemilatInf.has_forget_to_PartOrd SemilatInf.hasForgetToPartOrd
+#align SemilatInf.has_forget_to_PartOrd SemilatInfCat.hasForgetToPartOrd
 
 @[simp]
-theorem coe_forget_to_partOrdCat (X : SemilatInf) : ↥((forget₂ SemilatInf PartOrdCat).obj X) = ↥X :=
+theorem coe_forget_to_partOrdCat (X : SemilatInfCat) :
+    ↥((forget₂ SemilatInfCat PartOrdCat).obj X) = ↥X :=
   rfl
-#align SemilatInf.coe_forget_to_PartOrd SemilatInf.coe_forget_to_partOrdCat
+#align SemilatInf.coe_forget_to_PartOrd SemilatInfCat.coe_forget_to_partOrdCat
 
-end SemilatInf
+end SemilatInfCat
 
 /-! ### Order dual -/
 
 
-namespace SemilatSup
+namespace SemilatSupCat
 
 /-- Constructs an isomorphism of lattices from an order isomorphism between them. -/
 @[simps]
-def Iso.mk {α β : SemilatSup.{u}} (e : α ≃o β) : α ≅ β
+def Iso.mk {α β : SemilatSupCat.{u}} (e : α ≃o β) : α ≅ β
     where
   Hom := e
   inv := e.symm
   hom_inv_id' := by ext; exact e.symm_apply_apply _
   inv_hom_id' := by ext; exact e.apply_symm_apply _
-#align SemilatSup.iso.mk SemilatSup.Iso.mk
+#align SemilatSup.iso.mk SemilatSupCat.Iso.mk
 
 /-- `order_dual` as a functor. -/
 @[simps]
-def dual : SemilatSup ⥤ SemilatInf
+def dual : SemilatSupCat ⥤ SemilatInfCat
     where
-  obj X := SemilatInf.of Xᵒᵈ
+  obj X := SemilatInfCat.of Xᵒᵈ
   map X Y := SupBotHom.dual
-#align SemilatSup.dual SemilatSup.dual
+#align SemilatSup.dual SemilatSupCat.dual
 
-end SemilatSup
+end SemilatSupCat
 
-namespace SemilatInf
+namespace SemilatInfCat
 
 /-- Constructs an isomorphism of lattices from an order isomorphism between them. -/
 @[simps]
-def Iso.mk {α β : SemilatInf.{u}} (e : α ≃o β) : α ≅ β
+def Iso.mk {α β : SemilatInfCat.{u}} (e : α ≃o β) : α ≅ β
     where
   Hom := e
   inv := e.symm
   hom_inv_id' := by ext; exact e.symm_apply_apply _
   inv_hom_id' := by ext; exact e.apply_symm_apply _
-#align SemilatInf.iso.mk SemilatInf.Iso.mk
+#align SemilatInf.iso.mk SemilatInfCat.Iso.mk
 
 /-- `order_dual` as a functor. -/
 @[simps]
-def dual : SemilatInf ⥤ SemilatSup
+def dual : SemilatInfCat ⥤ SemilatSupCat
     where
-  obj X := SemilatSup.of Xᵒᵈ
+  obj X := SemilatSupCat.of Xᵒᵈ
   map X Y := InfTopHom.dual
-#align SemilatInf.dual SemilatInf.dual
+#align SemilatInf.dual SemilatInfCat.dual
 
-end SemilatInf
+end SemilatInfCat
 
 /-- The equivalence between `SemilatSup` and `SemilatInf` induced by `order_dual` both ways.
 -/
 @[simps Functor inverse]
-def semilatSupEquivSemilatInf : SemilatSup ≌ SemilatInf :=
-  Equivalence.mk SemilatSup.dual SemilatInf.dual
-    (NatIso.ofComponents (fun X => SemilatSup.Iso.mk <| OrderIso.dualDual X) fun X Y f => rfl)
-    (NatIso.ofComponents (fun X => SemilatInf.Iso.mk <| OrderIso.dualDual X) fun X Y f => rfl)
-#align SemilatSup_equiv_SemilatInf semilatSupEquivSemilatInf
-
-theorem semilatSup_dual_comp_forget_to_partOrdCat :
-    SemilatSup.dual ⋙ forget₂ SemilatInf PartOrdCat =
-      forget₂ SemilatSup PartOrdCat ⋙ PartOrdCat.dual :=
+def SemilatSupCatEquivSemilatInfCat : SemilatSupCat ≌ SemilatInfCat :=
+  Equivalence.mk SemilatSupCat.dual SemilatInfCat.dual
+    (NatIso.ofComponents (fun X => SemilatSupCat.Iso.mk <| OrderIso.dualDual X) fun X Y f => rfl)
+    (NatIso.ofComponents (fun X => SemilatInfCat.Iso.mk <| OrderIso.dualDual X) fun X Y f => rfl)
+#align SemilatSup_equiv_SemilatInf SemilatSupCatEquivSemilatInfCat
+
+theorem SemilatSupCat_dual_comp_forget_to_partOrdCat :
+    SemilatSupCat.dual ⋙ forget₂ SemilatInfCat PartOrdCat =
+      forget₂ SemilatSupCat PartOrdCat ⋙ PartOrdCat.dual :=
   rfl
-#align SemilatSup_dual_comp_forget_to_PartOrd semilatSup_dual_comp_forget_to_partOrdCat
+#align SemilatSup_dual_comp_forget_to_PartOrd SemilatSupCat_dual_comp_forget_to_partOrdCat
 
-theorem semilatInf_dual_comp_forget_to_partOrdCat :
-    SemilatInf.dual ⋙ forget₂ SemilatSup PartOrdCat =
-      forget₂ SemilatInf PartOrdCat ⋙ PartOrdCat.dual :=
+theorem SemilatInfCat_dual_comp_forget_to_partOrdCat :
+    SemilatInfCat.dual ⋙ forget₂ SemilatSupCat PartOrdCat =
+      forget₂ SemilatInfCat PartOrdCat ⋙ PartOrdCat.dual :=
   rfl
-#align SemilatInf_dual_comp_forget_to_PartOrd semilatInf_dual_comp_forget_to_partOrdCat
+#align SemilatInf_dual_comp_forget_to_PartOrd SemilatInfCat_dual_comp_forget_to_partOrdCat
 
Diff
@@ -152,12 +152,8 @@ def Iso.mk {α β : SemilatSup.{u}} (e : α ≃o β) : α ≅ β
     where
   Hom := e
   inv := e.symm
-  hom_inv_id' := by
-    ext
-    exact e.symm_apply_apply _
-  inv_hom_id' := by
-    ext
-    exact e.apply_symm_apply _
+  hom_inv_id' := by ext; exact e.symm_apply_apply _
+  inv_hom_id' := by ext; exact e.apply_symm_apply _
 #align SemilatSup.iso.mk SemilatSup.Iso.mk
 
 /-- `order_dual` as a functor. -/
@@ -178,12 +174,8 @@ def Iso.mk {α β : SemilatInf.{u}} (e : α ≃o β) : α ≅ β
     where
   Hom := e
   inv := e.symm
-  hom_inv_id' := by
-    ext
-    exact e.symm_apply_apply _
-  inv_hom_id' := by
-    ext
-    exact e.apply_symm_apply _
+  hom_inv_id' := by ext; exact e.symm_apply_apply _
+  inv_hom_id' := by ext; exact e.apply_symm_apply _
 #align SemilatInf.iso.mk SemilatInf.Iso.mk
 
 /-- `order_dual` as a functor. -/
Diff
@@ -79,16 +79,16 @@ instance : ConcreteCategory SemilatSup
       map := fun X Y => coeFn }
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
-instance hasForgetToPartOrd : HasForget₂ SemilatSup PartOrd
+instance hasForgetToPartOrd : HasForget₂ SemilatSup PartOrdCat
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
 #align SemilatSup.has_forget_to_PartOrd SemilatSup.hasForgetToPartOrd
 
 @[simp]
-theorem coe_forget_to_partOrd (X : SemilatSup) : ↥((forget₂ SemilatSup PartOrd).obj X) = ↥X :=
+theorem coe_forget_to_partOrdCat (X : SemilatSup) : ↥((forget₂ SemilatSup PartOrdCat).obj X) = ↥X :=
   rfl
-#align SemilatSup.coe_forget_to_PartOrd SemilatSup.coe_forget_to_partOrd
+#align SemilatSup.coe_forget_to_PartOrd SemilatSup.coe_forget_to_partOrdCat
 
 end SemilatSup
 
@@ -128,16 +128,16 @@ instance : ConcreteCategory SemilatInf
       map := fun X Y => coeFn }
   forget_faithful := ⟨fun X Y => FunLike.coe_injective⟩
 
-instance hasForgetToPartOrd : HasForget₂ SemilatInf PartOrd
+instance hasForgetToPartOrd : HasForget₂ SemilatInf PartOrdCat
     where forget₂ :=
     { obj := fun X => ⟨X⟩
       map := fun X Y f => f }
 #align SemilatInf.has_forget_to_PartOrd SemilatInf.hasForgetToPartOrd
 
 @[simp]
-theorem coe_forget_to_partOrd (X : SemilatInf) : ↥((forget₂ SemilatInf PartOrd).obj X) = ↥X :=
+theorem coe_forget_to_partOrdCat (X : SemilatInf) : ↥((forget₂ SemilatInf PartOrdCat).obj X) = ↥X :=
   rfl
-#align SemilatInf.coe_forget_to_PartOrd SemilatInf.coe_forget_to_partOrd
+#align SemilatInf.coe_forget_to_PartOrd SemilatInf.coe_forget_to_partOrdCat
 
 end SemilatInf
 
@@ -205,13 +205,15 @@ def semilatSupEquivSemilatInf : SemilatSup ≌ SemilatInf :=
     (NatIso.ofComponents (fun X => SemilatInf.Iso.mk <| OrderIso.dualDual X) fun X Y f => rfl)
 #align SemilatSup_equiv_SemilatInf semilatSupEquivSemilatInf
 
-theorem semilatSup_dual_comp_forget_to_partOrd :
-    SemilatSup.dual ⋙ forget₂ SemilatInf PartOrd = forget₂ SemilatSup PartOrd ⋙ PartOrd.dual :=
+theorem semilatSup_dual_comp_forget_to_partOrdCat :
+    SemilatSup.dual ⋙ forget₂ SemilatInf PartOrdCat =
+      forget₂ SemilatSup PartOrdCat ⋙ PartOrdCat.dual :=
   rfl
-#align SemilatSup_dual_comp_forget_to_PartOrd semilatSup_dual_comp_forget_to_partOrd
+#align SemilatSup_dual_comp_forget_to_PartOrd semilatSup_dual_comp_forget_to_partOrdCat
 
-theorem semilatInf_dual_comp_forget_to_partOrd :
-    SemilatInf.dual ⋙ forget₂ SemilatSup PartOrd = forget₂ SemilatInf PartOrd ⋙ PartOrd.dual :=
+theorem semilatInf_dual_comp_forget_to_partOrdCat :
+    SemilatInf.dual ⋙ forget₂ SemilatSup PartOrdCat =
+      forget₂ SemilatInf PartOrdCat ⋙ PartOrdCat.dual :=
   rfl
-#align SemilatInf_dual_comp_forget_to_PartOrd semilatInf_dual_comp_forget_to_partOrd
+#align SemilatInf_dual_comp_forget_to_PartOrd semilatInf_dual_comp_forget_to_partOrdCat
 

Changes in mathlib4

mathlib3
mathlib4
chore: classify added instance porting notes (#10755)

Classifies by adding issue number (#10754) to porting notes claiming added instance.

Diff
@@ -124,7 +124,7 @@ instance : LargeCategory.{u} SemilatInfCat where
   comp_id := InfTopHom.id_comp
   assoc _ _ _ := InfTopHom.comp_assoc _ _ _
 
--- Porting note: added
+-- Porting note (#10754): added instance
 instance instFunLike (X Y : SemilatInfCat) : FunLike (X ⟶ Y) X Y :=
   show FunLike (InfTopHom X Y) X Y from inferInstance
 
doc: @[inherit_doc] on notations (#9942)

Make all the notations that unambiguously should inherit the docstring of their definition actually inherit it.

Also write a few docstrings by hand. I only wrote the ones I was competent to write and which I was sure of. Some docstrings come from mathlib3 as they were lost during the early port.

This PR is only intended as a first pass There are many more docstrings to add.

Diff
@@ -27,6 +27,7 @@ open CategoryTheory
 
 /-- The category of sup-semilattices with a bottom element. -/
 structure SemilatSupCat : Type (u + 1) where
+  /-- The underlying type of a sup-semilattice with a bottom element. -/
   protected X : Type u
   [isSemilatticeSup : SemilatticeSup X]
   [isOrderBot : OrderBot.{u} X]
@@ -34,6 +35,7 @@ structure SemilatSupCat : Type (u + 1) where
 
 /-- The category of inf-semilattices with a top element. -/
 structure SemilatInfCat : Type (u + 1) where
+  /-- The underlying type of an inf-semilattice with a top element. -/
   protected X : Type u
   [isSemilatticeInf : SemilatticeInf X]
   [isOrderTop : OrderTop.{u} X]
refactor(*): abbreviation for non-dependent FunLike (#9833)

This follows up from #9785, which renamed FunLike to DFunLike, by introducing a new abbreviation FunLike F α β := DFunLike F α (fun _ => β), to make the non-dependent use of FunLike easier.

I searched for the pattern DFunLike.*fun and DFunLike.*λ in all files to replace expressions of the form DFunLike F α (fun _ => β) with FunLike F α β. I did this everywhere except for extends clauses for two reasons: it would conflict with #8386, and more importantly extends must directly refer to a structure with no unfolding of defs or abbrevs.

Diff
@@ -69,8 +69,8 @@ instance : LargeCategory.{u} SemilatSupCat where
 
 -- Porting note: added
 -- see https://github.com/leanprover-community/mathlib4/issues/5017
-instance instDFunLike (X Y : SemilatSupCat) : DFunLike (X ⟶ Y) X (fun _ => Y) :=
-  show DFunLike (SupBotHom X Y) X (fun _ => Y) from inferInstance
+instance instFunLike (X Y : SemilatSupCat) : FunLike (X ⟶ Y) X Y :=
+  show FunLike (SupBotHom X Y) X Y from inferInstance
 
 instance : ConcreteCategory SemilatSupCat where
   forget :=
@@ -123,8 +123,8 @@ instance : LargeCategory.{u} SemilatInfCat where
   assoc _ _ _ := InfTopHom.comp_assoc _ _ _
 
 -- Porting note: added
-instance instDFunLike (X Y : SemilatInfCat) : DFunLike (X ⟶ Y) X (fun _ => Y) :=
-  show DFunLike (InfTopHom X Y) X (fun _ => Y) from inferInstance
+instance instFunLike (X Y : SemilatInfCat) : FunLike (X ⟶ Y) X Y :=
+  show FunLike (InfTopHom X Y) X Y from inferInstance
 
 instance : ConcreteCategory SemilatInfCat where
   forget :=
chore(*): rename FunLike to DFunLike (#9785)

This prepares for the introduction of a non-dependent synonym of FunLike, which helps a lot with keeping #8386 readable.

This is entirely search-and-replace in 680197f combined with manual fixes in 4145626, e900597 and b8428f8. The commands that generated this change:

sed -i 's/\bFunLike\b/DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoFunLike\b/toDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/import Mathlib.Data.DFunLike/import Mathlib.Data.FunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bHom_FunLike\b/Hom_DFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean     
sed -i 's/\binstFunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\bfunLike\b/instDFunLike/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean
sed -i 's/\btoo many metavariables to apply `fun_like.has_coe_to_fun`/too many metavariables to apply `DFunLike.hasCoeToFun`/g' {Archive,Counterexamples,Mathlib,test}/**/*.lean

Co-authored-by: Anne Baanen <Vierkantor@users.noreply.github.com>

Diff
@@ -69,14 +69,14 @@ instance : LargeCategory.{u} SemilatSupCat where
 
 -- Porting note: added
 -- see https://github.com/leanprover-community/mathlib4/issues/5017
-instance instFunLike (X Y : SemilatSupCat) : FunLike (X ⟶ Y) X (fun _ => Y) :=
-  show FunLike (SupBotHom X Y) X (fun _ => Y) from inferInstance
+instance instDFunLike (X Y : SemilatSupCat) : DFunLike (X ⟶ Y) X (fun _ => Y) :=
+  show DFunLike (SupBotHom X Y) X (fun _ => Y) from inferInstance
 
 instance : ConcreteCategory SemilatSupCat where
   forget :=
     { obj := SemilatSupCat.X
-      map := FunLike.coe }
-  forget_faithful := ⟨(FunLike.coe_injective ·)⟩
+      map := DFunLike.coe }
+  forget_faithful := ⟨(DFunLike.coe_injective ·)⟩
 
 instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrd where
   forget₂ :=
@@ -123,14 +123,14 @@ instance : LargeCategory.{u} SemilatInfCat where
   assoc _ _ _ := InfTopHom.comp_assoc _ _ _
 
 -- Porting note: added
-instance instFunLike (X Y : SemilatInfCat) : FunLike (X ⟶ Y) X (fun _ => Y) :=
-  show FunLike (InfTopHom X Y) X (fun _ => Y) from inferInstance
+instance instDFunLike (X Y : SemilatInfCat) : DFunLike (X ⟶ Y) X (fun _ => Y) :=
+  show DFunLike (InfTopHom X Y) X (fun _ => Y) from inferInstance
 
 instance : ConcreteCategory SemilatInfCat where
   forget :=
     { obj := SemilatInfCat.X
-      map := FunLike.coe }
-  forget_faithful := ⟨(FunLike.coe_injective ·)⟩
+      map := DFunLike.coe }
+  forget_faithful := ⟨(DFunLike.coe_injective ·)⟩
 
 instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrd where
   forget₂ :=
chore: Remove Cat suffixes (#3730)

These names needn't change in the first place.

Diff
@@ -3,7 +3,7 @@ Copyright (c) 2022 Yaël Dillies. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
 -/
-import Mathlib.Order.Category.PartOrdCat
+import Mathlib.Order.Category.PartOrd
 import Mathlib.Order.Hom.Lattice
 
 #align_import order.category.Semilat from "leanprover-community/mathlib"@"e8ac6315bcfcbaf2d19a046719c3b553206dac75"
@@ -78,7 +78,7 @@ instance : ConcreteCategory SemilatSupCat where
       map := FunLike.coe }
   forget_faithful := ⟨(FunLike.coe_injective ·)⟩
 
-instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrdCat where
+instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrd where
   forget₂ :=
     -- Porting note: was ⟨X⟩, see https://github.com/leanprover-community/mathlib4/issues/4998
     { obj := fun X => {α := X}
@@ -87,10 +87,10 @@ instance hasForgetToPartOrd : HasForget₂ SemilatSupCat PartOrdCat where
 #align SemilatSup.has_forget_to_PartOrd SemilatSupCat.hasForgetToPartOrd
 
 @[simp]
-theorem coe_forget_to_partOrdCat (X : SemilatSupCat) :
-    ↥((forget₂ SemilatSupCat PartOrdCat).obj X) = ↥X :=
+theorem coe_forget_to_partOrd (X : SemilatSupCat) :
+    ↥((forget₂ SemilatSupCat PartOrd).obj X) = ↥X :=
   rfl
-#align SemilatSup.coe_forget_to_PartOrd SemilatSupCat.coe_forget_to_partOrdCat
+#align SemilatSup.coe_forget_to_PartOrd SemilatSupCat.coe_forget_to_partOrd
 
 end SemilatSupCat
 
@@ -132,7 +132,7 @@ instance : ConcreteCategory SemilatInfCat where
       map := FunLike.coe }
   forget_faithful := ⟨(FunLike.coe_injective ·)⟩
 
-instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrdCat where
+instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrd where
   forget₂ :=
     { obj := fun X => ⟨X, inferInstance⟩
       -- Porting note: was `map := fun f => f`
@@ -140,10 +140,10 @@ instance hasForgetToPartOrd : HasForget₂ SemilatInfCat PartOrdCat where
 #align SemilatInf.has_forget_to_PartOrd SemilatInfCat.hasForgetToPartOrd
 
 @[simp]
-theorem coe_forget_to_partOrdCat (X : SemilatInfCat) :
-    ↥((forget₂ SemilatInfCat PartOrdCat).obj X) = ↥X :=
+theorem coe_forget_to_partOrd (X : SemilatInfCat) :
+    ↥((forget₂ SemilatInfCat PartOrd).obj X) = ↥X :=
   rfl
-#align SemilatInf.coe_forget_to_PartOrd SemilatInfCat.coe_forget_to_partOrdCat
+#align SemilatInf.coe_forget_to_PartOrd SemilatInfCat.coe_forget_to_partOrd
 
 end SemilatInfCat
 
@@ -198,14 +198,14 @@ def SemilatSupCatEquivSemilatInfCat : SemilatSupCat ≌ SemilatInfCat where
   counitIso := NatIso.ofComponents fun X => SemilatInfCat.Iso.mk <| OrderIso.dualDual X
 #align SemilatSup_equiv_SemilatInf SemilatSupCatEquivSemilatInfCat
 
-theorem SemilatSupCat_dual_comp_forget_to_partOrdCat :
-    SemilatSupCat.dual ⋙ forget₂ SemilatInfCat PartOrdCat =
-      forget₂ SemilatSupCat PartOrdCat ⋙ PartOrdCat.dual :=
+theorem SemilatSupCat_dual_comp_forget_to_partOrd :
+    SemilatSupCat.dual ⋙ forget₂ SemilatInfCat PartOrd =
+      forget₂ SemilatSupCat PartOrd ⋙ PartOrd.dual :=
   rfl
-#align SemilatSup_dual_comp_forget_to_PartOrd SemilatSupCat_dual_comp_forget_to_partOrdCat
+#align SemilatSup_dual_comp_forget_to_PartOrd SemilatSupCat_dual_comp_forget_to_partOrd
 
-theorem SemilatInfCat_dual_comp_forget_to_partOrdCat :
-    SemilatInfCat.dual ⋙ forget₂ SemilatSupCat PartOrdCat =
-      forget₂ SemilatInfCat PartOrdCat ⋙ PartOrdCat.dual :=
+theorem SemilatInfCat_dual_comp_forget_to_partOrd :
+    SemilatInfCat.dual ⋙ forget₂ SemilatSupCat PartOrd =
+      forget₂ SemilatInfCat PartOrd ⋙ PartOrd.dual :=
   rfl
-#align SemilatInf_dual_comp_forget_to_PartOrd SemilatInfCat_dual_comp_forget_to_partOrdCat
+#align SemilatInf_dual_comp_forget_to_PartOrd SemilatInfCat_dual_comp_forget_to_partOrd
chore: banish Type _ and Sort _ (#6499)

We remove all possible occurences of Type _ and Sort _ in favor of Type* and Sort*.

This has nice performance benefits.

Diff
@@ -41,18 +41,18 @@ structure SemilatInfCat : Type (u + 1) where
 
 namespace SemilatSupCat
 
-instance : CoeSort SemilatSupCat (Type _) :=
+instance : CoeSort SemilatSupCat (Type*) :=
   ⟨SemilatSupCat.X⟩
 
 attribute [instance] isSemilatticeSup isOrderBot
 
 /-- Construct a bundled `SemilatSupCat` from a `SemilatticeSup`. -/
-def of (α : Type _) [SemilatticeSup α] [OrderBot α] : SemilatSupCat :=
+def of (α : Type*) [SemilatticeSup α] [OrderBot α] : SemilatSupCat :=
   ⟨α⟩
 #align SemilatSup.of SemilatSupCat.of
 
 @[simp]
-theorem coe_of (α : Type _) [SemilatticeSup α] [OrderBot α] : ↥(of α) = α :=
+theorem coe_of (α : Type*) [SemilatticeSup α] [OrderBot α] : ↥(of α) = α :=
   rfl
 #align SemilatSup.coe_of SemilatSupCat.coe_of
 
@@ -96,18 +96,18 @@ end SemilatSupCat
 
 namespace SemilatInfCat
 
-instance : CoeSort SemilatInfCat (Type _) :=
+instance : CoeSort SemilatInfCat (Type*) :=
   ⟨SemilatInfCat.X⟩
 
 attribute [instance] isSemilatticeInf isOrderTop
 
 /-- Construct a bundled `SemilatInfCat` from a `SemilatticeInf`. -/
-def of (α : Type _) [SemilatticeInf α] [OrderTop α] : SemilatInfCat :=
+def of (α : Type*) [SemilatticeInf α] [OrderTop α] : SemilatInfCat :=
   ⟨α⟩
 #align SemilatInf.of SemilatInfCat.of
 
 @[simp]
-theorem coe_of (α : Type _) [SemilatticeInf α] [OrderTop α] : ↥(of α) = α :=
+theorem coe_of (α : Type*) [SemilatticeInf α] [OrderTop α] : ↥(of α) = α :=
   rfl
 #align SemilatInf.coe_of SemilatInfCat.coe_of
 
chore: script to replace headers with #align_import statements (#5979)

Open in Gitpod

Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -2,15 +2,12 @@
 Copyright (c) 2022 Yaël Dillies. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
-
-! This file was ported from Lean 3 source module order.category.Semilat
-! leanprover-community/mathlib commit e8ac6315bcfcbaf2d19a046719c3b553206dac75
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Order.Category.PartOrdCat
 import Mathlib.Order.Hom.Lattice
 
+#align_import order.category.Semilat from "leanprover-community/mathlib"@"e8ac6315bcfcbaf2d19a046719c3b553206dac75"
+
 /-!
 # The categories of semilattices
 
chore: tidy various files (#5458)
Diff
@@ -163,7 +163,7 @@ def Iso.mk {α β : SemilatSupCat.{u}} (e : α ≃o β) : α ≅ β where
   inv_hom_id := by ext; exact e.apply_symm_apply _
 #align SemilatSup.iso.mk SemilatSupCat.Iso.mk
 
-/-- `order_dual` as a functor. -/
+/-- `OrderDual` as a functor. -/
 @[simps]
 def dual : SemilatSupCat ⥤ SemilatInfCat where
   obj X := SemilatInfCat.of Xᵒᵈ
feat: port Order.Category.CompleteLatCat (#5019)

Co-authored-by: Yaël Dillies <yael.dillies@gmail.com>

Diff
@@ -71,6 +71,7 @@ instance : LargeCategory.{u} SemilatSupCat where
   assoc _ _ _ := SupBotHom.comp_assoc _ _ _
 
 -- Porting note: added
+-- see https://github.com/leanprover-community/mathlib4/issues/5017
 instance instFunLike (X Y : SemilatSupCat) : FunLike (X ⟶ Y) X (fun _ => Y) :=
   show FunLike (SupBotHom X Y) X (fun _ => Y) from inferInstance
 
feat: port Order.Category.SemilatCat (#4990)

Co-authored-by: Jeremy Tan Jie Rui <reddeloostw@gmail.com> Co-authored-by: Johan Commelin <johan@commelin.net>

Dependencies 120

121 files ported (100.0%)
48110 lines ported (100.0%)

All dependencies are ported!