group_theory.subsemigroup.basicMathlib.GroupTheory.Subsemigroup.Basic

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)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(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)

fix(data/set_like): unbundled subclasses of out_param classes should not repeat the parents' out_param (#18291)

This PR is a backport for a mathlib4 fix for a large amount of issues encountered in the port of group_theory.subgroup.basic, leanprover-community/mathlib4#1797. Subobject classes such as mul_mem_class and submonoid_class take a set_like parameter, and we were used to just copy over the M : out_param Type declaration from set_like. Since Lean 3 synthesizes from left to right, we'd fill in the out_param from set_like, then the has_mul M instance would be available for synthesis and we'd be in business. In Lean 4 however, we will often go from right to left, so that MulMemClass ?M S [?inst : Mul ?M] is handled first, which can't be solved before finding a Mul ?M instance on the metavariable ?M, causing search through all Mul instances.

The solution is: whenever a class is declared that takes another class as parameter (i.e. unbundled inheritance), the out_params of the parent class should be unmarked and become in-params in the child class. Then Lean will try to find the parent class instance first, fill in the out_params and we'll be able to synthesize the child class instance without problems.

One consequence is that sometimes we have to give slightly more type ascription when talking about membership and the types don't quite align: if M and M' are semireducibly defeq, then before zero_mem_class S M would work to prove (0 : M') ∈ (s : S), since the out_param became a metavariable, was filled in, and then checked (up to semireducibility apparently) for equality. Now M is checked to equal M' before applying the instance, with instance-reducible transparency. I don't think this is a huge issue since it feels Lean 4 is stricter about these kinds of equalities anyway.

Mathlib4 pair: leanprover-community/mathlib4#1832

Diff
@@ -57,13 +57,13 @@ variables [has_mul M] {s : set M}
 variables [has_add A] {t : set A}
 
 /-- `mul_mem_class S M` says `S` is a type of subsets `s ≤ M` that are closed under `(*)` -/
-class mul_mem_class (S : Type*) (M : out_param $ Type*) [has_mul M] [set_like S M] : Prop :=
+class mul_mem_class (S M : Type*) [has_mul M] [set_like S M] : Prop :=
 (mul_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a * b ∈ s)
 
 export mul_mem_class (mul_mem)
 
 /-- `add_mem_class S M` says `S` is a type of subsets `s ≤ M` that are closed under `(+)` -/
-class add_mem_class (S : Type*) (M : out_param $ Type*) [has_add M] [set_like S M] : Prop :=
+class add_mem_class (S M : Type*) [has_add M] [set_like S M] : Prop :=
 (add_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a + b ∈ s)
 
 export add_mem_class (add_mem)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

fix(*): mark some classes as Prop (#18015)
Diff
@@ -54,13 +54,13 @@ variables [has_mul M] {s : set M}
 variables [has_add A] {t : set A}
 
 /-- `mul_mem_class S M` says `S` is a type of subsets `s ≤ M` that are closed under `(*)` -/
-class mul_mem_class (S : Type*) (M : out_param $ Type*) [has_mul M] [set_like S M] :=
+class mul_mem_class (S : Type*) (M : out_param $ Type*) [has_mul M] [set_like S M] : Prop :=
 (mul_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a * b ∈ s)
 
 export mul_mem_class (mul_mem)
 
 /-- `add_mem_class S M` says `S` is a type of subsets `s ≤ M` that are closed under `(+)` -/
-class add_mem_class (S : Type*) (M : out_param $ Type*) [has_add M] [set_like S M] :=
+class add_mem_class (S : Type*) (M : out_param $ Type*) [has_add M] [set_like S M] : Prop :=
 (add_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a + b ∈ s)
 
 export add_mem_class (add_mem)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(first ported)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzzard,
 Amelia Livingston, Yury Kudryashov, Yakov Pechersky
 -/
-import Algebra.Hom.Group
+import Algebra.Group.Hom.Defs
 import Data.Set.Lattice
 import Data.SetLike.Basic
 
Diff
@@ -301,7 +301,7 @@ theorem mem_sInf {S : Set (Subsemigroup M)} {x : M} : x ∈ sInf S ↔ ∀ p ∈
 #print Subsemigroup.mem_iInf /-
 @[to_additive]
 theorem mem_iInf {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
-  simp only [iInf, mem_Inf, Set.forall_range_iff]
+  simp only [iInf, mem_Inf, Set.forall_mem_range]
 #align subsemigroup.mem_infi Subsemigroup.mem_iInf
 #align add_subsemigroup.mem_infi AddSubsemigroup.mem_iInf
 -/
Diff
@@ -4,9 +4,9 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzzard,
 Amelia Livingston, Yury Kudryashov, Yakov Pechersky
 -/
-import Mathbin.Algebra.Hom.Group
-import Mathbin.Data.Set.Lattice
-import Mathbin.Data.SetLike.Basic
+import Algebra.Hom.Group
+import Data.Set.Lattice
+import Data.SetLike.Basic
 
 #align_import group_theory.subsemigroup.basic from "leanprover-community/mathlib"@"feb99064803fd3108e37c18b0f77d0a8344677a3"
 
Diff
@@ -67,11 +67,11 @@ variable [Add A] {t : Set A}
 #print MulMemClass /-
 /-- `mul_mem_class S M` says `S` is a type of subsets `s ≤ M` that are closed under `(*)` -/
 class MulMemClass (S M : Type _) [Mul M] [SetLike S M] : Prop where
-  mul_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a * b ∈ s
+  hMul_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a * b ∈ s
 #align mul_mem_class MulMemClass
 -/
 
-export MulMemClass (mul_mem)
+export MulMemClass (hMul_mem)
 
 #print AddMemClass /-
 /-- `add_mem_class S M` says `S` is a type of subsets `s ≤ M` that are closed under `(+)` -/
@@ -88,7 +88,7 @@ attribute [to_additive] MulMemClass
 /-- A subsemigroup of a magma `M` is a subset closed under multiplication. -/
 structure Subsemigroup (M : Type _) [Mul M] where
   carrier : Set M
-  mul_mem' {a b} : a ∈ carrier → b ∈ carrier → a * b ∈ carrier
+  hMul_mem' {a b} : a ∈ carrier → b ∈ carrier → a * b ∈ carrier
 #align subsemigroup Subsemigroup
 -/
 
@@ -109,7 +109,7 @@ instance : SetLike (Subsemigroup M) M :=
   ⟨Subsemigroup.carrier, fun p q h => by cases p <;> cases q <;> congr⟩
 
 @[to_additive]
-instance : MulMemClass (Subsemigroup M) M where mul_mem := Subsemigroup.mul_mem'
+instance : MulMemClass (Subsemigroup M) M where hMul_mem := Subsemigroup.hMul_mem'
 
 /-- See Note [custom simps projection] -/
 @[to_additive " See Note [custom simps projection]"]
@@ -169,7 +169,7 @@ theorem ext {S T : Subsemigroup M} (h : ∀ x, x ∈ S ↔ x ∈ T) : S = T :=
 protected def copy (S : Subsemigroup M) (s : Set M) (hs : s = S) : Subsemigroup M
     where
   carrier := s
-  mul_mem' _ _ := hs.symm ▸ S.mul_mem'
+  hMul_mem' _ _ := hs.symm ▸ S.hMul_mem'
 #align subsemigroup.copy Subsemigroup.copy
 #align add_subsemigroup.copy AddSubsemigroup.copy
 -/
@@ -198,7 +198,7 @@ variable (S)
 /-- A subsemigroup is closed under multiplication. -/
 @[to_additive "An `add_subsemigroup` is closed under addition."]
 protected theorem mul_mem {x y : M} : x ∈ S → y ∈ S → x * y ∈ S :=
-  Subsemigroup.mul_mem' S
+  Subsemigroup.hMul_mem' S
 #align subsemigroup.mul_mem Subsemigroup.mul_mem
 #align add_subsemigroup.add_mem AddSubsemigroup.add_mem
 -/
@@ -207,13 +207,13 @@ protected theorem mul_mem {x y : M} : x ∈ S → y ∈ S → x * y ∈ S :=
 @[to_additive "The additive subsemigroup `M` of the magma `M`."]
 instance : Top (Subsemigroup M) :=
   ⟨{  carrier := Set.univ
-      mul_mem' := fun _ _ _ _ => Set.mem_univ _ }⟩
+      hMul_mem' := fun _ _ _ _ => Set.mem_univ _ }⟩
 
 /-- The trivial subsemigroup `∅` of a magma `M`. -/
 @[to_additive "The trivial `add_subsemigroup` `∅` of an additive magma `M`."]
 instance : Bot (Subsemigroup M) :=
   ⟨{  carrier := ∅
-      mul_mem' := fun a b => by simp }⟩
+      hMul_mem' := fun a b => by simp }⟩
 
 @[to_additive]
 instance : Inhabited (Subsemigroup M) :=
@@ -256,7 +256,7 @@ theorem coe_bot : ((⊥ : Subsemigroup M) : Set M) = ∅ :=
 instance : Inf (Subsemigroup M) :=
   ⟨fun S₁ S₂ =>
     { carrier := S₁ ∩ S₂
-      mul_mem' := fun _ _ ⟨hx, hx'⟩ ⟨hy, hy'⟩ => ⟨S₁.mul_mem hx hy, S₂.mul_mem hx' hy'⟩ }⟩
+      hMul_mem' := fun _ _ ⟨hx, hx'⟩ ⟨hy, hy'⟩ => ⟨S₁.hMul_mem hx hy, S₂.hMul_mem hx' hy'⟩ }⟩
 
 #print Subsemigroup.coe_inf /-
 @[simp, to_additive]
@@ -278,9 +278,9 @@ theorem mem_inf {p p' : Subsemigroup M} {x : M} : x ∈ p ⊓ p' ↔ x ∈ p ∧
 instance : InfSet (Subsemigroup M) :=
   ⟨fun s =>
     { carrier := ⋂ t ∈ s, ↑t
-      mul_mem' := fun x y hx hy =>
+      hMul_mem' := fun x y hx hy =>
         Set.mem_biInter fun i h =>
-          i.mul_mem (by apply Set.mem_iInter₂.1 hx i h) (by apply Set.mem_iInter₂.1 hy i h) }⟩
+          i.hMul_mem (by apply Set.mem_iInter₂.1 hx i h) (by apply Set.mem_iInter₂.1 hy i h) }⟩
 
 #print Subsemigroup.coe_sInf /-
 @[simp, norm_cast, to_additive]
@@ -434,7 +434,7 @@ theorem closure_induction {p : M → Prop} {x} (h : x ∈ closure s) (Hs : ∀ x
 @[elab_as_elim, to_additive "A dependent version of `add_subsemigroup.closure_induction`. "]
 theorem closure_induction' (s : Set M) {p : ∀ x, x ∈ closure s → Prop}
     (Hs : ∀ (x) (h : x ∈ s), p x (subset_closure h))
-    (Hmul : ∀ x hx y hy, p x hx → p y hy → p (x * y) (mul_mem hx hy)) {x} (hx : x ∈ closure s) :
+    (Hmul : ∀ x hx y hy, p x hx → p y hy → p (x * y) (hMul_mem hx hy)) {x} (hx : x ∈ closure s) :
     p x hx := by
   refine' Exists.elim _ fun (hx : x ∈ closure s) (hc : p x hx) => hc
   exact
@@ -575,7 +575,7 @@ open Subsemigroup
 def eqLocus (f g : M →ₙ* N) : Subsemigroup M
     where
   carrier := {x | f x = g x}
-  mul_mem' x y (hx : _ = _) (hy : _ = _) := by simp [*]
+  hMul_mem' x y (hx : _ = _) (hy : _ = _) := by simp [*]
 #align mul_hom.eq_mlocus MulHom.eqLocus
 #align add_hom.eq_mlocus AddHom.eqLocus
 -/
Diff
@@ -3,16 +3,13 @@ Copyright (c) 2018 Johannes Hölzl. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzzard,
 Amelia Livingston, Yury Kudryashov, Yakov Pechersky
-
-! This file was ported from Lean 3 source module group_theory.subsemigroup.basic
-! leanprover-community/mathlib commit feb99064803fd3108e37c18b0f77d0a8344677a3
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.Algebra.Hom.Group
 import Mathbin.Data.Set.Lattice
 import Mathbin.Data.SetLike.Basic
 
+#align_import group_theory.subsemigroup.basic from "leanprover-community/mathlib"@"feb99064803fd3108e37c18b0f77d0a8344677a3"
+
 /-!
 # Subsemigroups: definition and `complete_lattice` structure
 
Diff
@@ -149,11 +149,13 @@ theorem coe_set_mk {s : Set M} (h_mul) : (mk s h_mul : Set M) = s :=
 #align add_subsemigroup.coe_set_mk AddSubsemigroup.coe_set_mk
 -/
 
+#print Subsemigroup.mk_le_mk /-
 @[simp, to_additive]
 theorem mk_le_mk {s t : Set M} (h_mul) (h_mul') : mk s h_mul ≤ mk t h_mul' ↔ s ⊆ t :=
   Iff.rfl
 #align subsemigroup.mk_le_mk Subsemigroup.mk_le_mk
 #align add_subsemigroup.mk_le_mk AddSubsemigroup.mk_le_mk
+-/
 
 #print Subsemigroup.ext /-
 /-- Two subsemigroups are equal if they have the same elements. -/
@@ -259,17 +261,21 @@ instance : Inf (Subsemigroup M) :=
     { carrier := S₁ ∩ S₂
       mul_mem' := fun _ _ ⟨hx, hx'⟩ ⟨hy, hy'⟩ => ⟨S₁.mul_mem hx hy, S₂.mul_mem hx' hy'⟩ }⟩
 
+#print Subsemigroup.coe_inf /-
 @[simp, to_additive]
 theorem coe_inf (p p' : Subsemigroup M) : ((p ⊓ p' : Subsemigroup M) : Set M) = p ∩ p' :=
   rfl
 #align subsemigroup.coe_inf Subsemigroup.coe_inf
 #align add_subsemigroup.coe_inf AddSubsemigroup.coe_inf
+-/
 
+#print Subsemigroup.mem_inf /-
 @[simp, to_additive]
 theorem mem_inf {p p' : Subsemigroup M} {x : M} : x ∈ p ⊓ p' ↔ x ∈ p ∧ x ∈ p' :=
   Iff.rfl
 #align subsemigroup.mem_inf Subsemigroup.mem_inf
 #align add_subsemigroup.mem_inf AddSubsemigroup.mem_inf
+-/
 
 @[to_additive]
 instance : InfSet (Subsemigroup M) :=
@@ -279,29 +285,37 @@ instance : InfSet (Subsemigroup M) :=
         Set.mem_biInter fun i h =>
           i.mul_mem (by apply Set.mem_iInter₂.1 hx i h) (by apply Set.mem_iInter₂.1 hy i h) }⟩
 
+#print Subsemigroup.coe_sInf /-
 @[simp, norm_cast, to_additive]
 theorem coe_sInf (S : Set (Subsemigroup M)) : ((sInf S : Subsemigroup M) : Set M) = ⋂ s ∈ S, ↑s :=
   rfl
 #align subsemigroup.coe_Inf Subsemigroup.coe_sInf
 #align add_subsemigroup.coe_Inf AddSubsemigroup.coe_sInf
+-/
 
+#print Subsemigroup.mem_sInf /-
 @[to_additive]
 theorem mem_sInf {S : Set (Subsemigroup M)} {x : M} : x ∈ sInf S ↔ ∀ p ∈ S, x ∈ p :=
   Set.mem_iInter₂
 #align subsemigroup.mem_Inf Subsemigroup.mem_sInf
 #align add_subsemigroup.mem_Inf AddSubsemigroup.mem_sInf
+-/
 
+#print Subsemigroup.mem_iInf /-
 @[to_additive]
 theorem mem_iInf {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
   simp only [iInf, mem_Inf, Set.forall_range_iff]
 #align subsemigroup.mem_infi Subsemigroup.mem_iInf
 #align add_subsemigroup.mem_infi AddSubsemigroup.mem_iInf
+-/
 
+#print Subsemigroup.coe_iInf /-
 @[simp, norm_cast, to_additive]
 theorem coe_iInf {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
   simp only [iInf, coe_Inf, Set.biInter_range]
 #align subsemigroup.coe_infi Subsemigroup.coe_iInf
 #align add_subsemigroup.coe_infi AddSubsemigroup.coe_iInf
+-/
 
 /-- subsemigroups of a monoid form a complete lattice. -/
 @[to_additive "The `add_subsemigroup`s of an `add_monoid` form a complete lattice."]
@@ -374,6 +388,7 @@ variable {S}
 
 open Set
 
+#print Subsemigroup.closure_le /-
 /-- A subsemigroup `S` includes `closure s` if and only if it includes `s`. -/
 @[simp,
   to_additive "An additive subsemigroup `S` includes `closure s`\nif and only if it includes `s`"]
@@ -381,7 +396,9 @@ theorem closure_le : closure s ≤ S ↔ s ⊆ S :=
   ⟨Subset.trans subset_closure, fun h => sInf_le h⟩
 #align subsemigroup.closure_le Subsemigroup.closure_le
 #align add_subsemigroup.closure_le AddSubsemigroup.closure_le
+-/
 
+#print Subsemigroup.closure_mono /-
 /-- subsemigroup closure of a set is monotone in its argument: if `s ⊆ t`,
 then `closure s ≤ closure t`. -/
 @[to_additive
@@ -390,12 +407,15 @@ theorem closure_mono ⦃s t : Set M⦄ (h : s ⊆ t) : closure s ≤ closure t :
   closure_le.2 <| Subset.trans h subset_closure
 #align subsemigroup.closure_mono Subsemigroup.closure_mono
 #align add_subsemigroup.closure_mono AddSubsemigroup.closure_mono
+-/
 
+#print Subsemigroup.closure_eq_of_le /-
 @[to_additive]
 theorem closure_eq_of_le (h₁ : s ⊆ S) (h₂ : S ≤ closure s) : closure s = S :=
   le_antisymm (closure_le.2 h₁) h₂
 #align subsemigroup.closure_eq_of_le Subsemigroup.closure_eq_of_le
 #align add_subsemigroup.closure_eq_of_le AddSubsemigroup.closure_eq_of_le
+-/
 
 variable (S)
 
@@ -460,6 +480,7 @@ theorem dense_induction {p : M → Prop} (x : M) {s : Set M} (hs : closure s = 
 
 variable (M)
 
+#print Subsemigroup.gi /-
 /-- `closure` forms a Galois insertion with the coercion to set. -/
 @[to_additive "`closure` forms a Galois insertion with the coercion to set."]
 protected def gi : GaloisInsertion (@closure M _) coe
@@ -470,6 +491,7 @@ protected def gi : GaloisInsertion (@closure M _) coe
   choice_eq s h := rfl
 #align subsemigroup.gi Subsemigroup.gi
 #align add_subsemigroup.gi AddSubsemigroup.gi
+-/
 
 variable {M}
 
@@ -498,24 +520,31 @@ theorem closure_univ : closure (univ : Set M) = ⊤ :=
 #align add_subsemigroup.closure_univ AddSubsemigroup.closure_univ
 -/
 
+#print Subsemigroup.closure_union /-
 @[to_additive]
 theorem closure_union (s t : Set M) : closure (s ∪ t) = closure s ⊔ closure t :=
   (Subsemigroup.gi M).gc.l_sup
 #align subsemigroup.closure_union Subsemigroup.closure_union
 #align add_subsemigroup.closure_union AddSubsemigroup.closure_union
+-/
 
+#print Subsemigroup.closure_iUnion /-
 @[to_additive]
 theorem closure_iUnion {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, closure (s i) :=
   (Subsemigroup.gi M).gc.l_iSup
 #align subsemigroup.closure_Union Subsemigroup.closure_iUnion
 #align add_subsemigroup.closure_Union AddSubsemigroup.closure_iUnion
+-/
 
+#print Subsemigroup.closure_singleton_le_iff_mem /-
 @[simp, to_additive]
 theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m} ≤ p ↔ m ∈ p := by
   rw [closure_le, singleton_subset_iff, SetLike.mem_coe]
 #align subsemigroup.closure_singleton_le_iff_mem Subsemigroup.closure_singleton_le_iff_mem
 #align add_subsemigroup.closure_singleton_le_iff_mem AddSubsemigroup.closure_singleton_le_iff_mem
+-/
 
+#print Subsemigroup.mem_iSup /-
 @[to_additive]
 theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
     (m ∈ ⨆ i, p i) ↔ ∀ N, (∀ i, p i ≤ N) → m ∈ N :=
@@ -524,13 +553,16 @@ theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
   simp only [closure_singleton_le_iff_mem]
 #align subsemigroup.mem_supr Subsemigroup.mem_iSup
 #align add_subsemigroup.mem_supr AddSubsemigroup.mem_iSup
+-/
 
+#print Subsemigroup.iSup_eq_closure /-
 @[to_additive]
 theorem iSup_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
     (⨆ i, p i) = Subsemigroup.closure (⋃ i, (p i : Set M)) := by
   simp_rw [Subsemigroup.closure_iUnion, Subsemigroup.closure_eq]
 #align subsemigroup.supr_eq_closure Subsemigroup.iSup_eq_closure
 #align add_subsemigroup.supr_eq_closure AddSubsemigroup.iSup_eq_closure
+-/
 
 end Subsemigroup
 
@@ -551,6 +583,7 @@ def eqLocus (f g : M →ₙ* N) : Subsemigroup M
 #align add_hom.eq_mlocus AddHom.eqLocus
 -/
 
+#print MulHom.eqOn_closure /-
 /-- If two mul homomorphisms are equal on a set, then they are equal on its subsemigroup closure. -/
 @[to_additive
       "If two add homomorphisms are equal on a set,\nthen they are equal on its additive subsemigroup closure."]
@@ -558,19 +591,24 @@ theorem eqOn_closure {f g : M →ₙ* N} {s : Set M} (h : Set.EqOn f g s) : Set.
   show closure s ≤ f.eqLocus g from closure_le.2 h
 #align mul_hom.eq_on_mclosure MulHom.eqOn_closure
 #align add_hom.eq_on_mclosure AddHom.eqOn_closure
+-/
 
+#print MulHom.eq_of_eqOn_top /-
 @[to_additive]
 theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup M)) : f = g :=
   ext fun x => h trivial
 #align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eqOn_top
 #align add_hom.eq_of_eq_on_mtop AddHom.eq_of_eqOn_top
+-/
 
+#print MulHom.eq_of_eqOn_dense /-
 @[to_additive]
 theorem eq_of_eqOn_dense {s : Set M} (hs : closure s = ⊤) {f g : M →ₙ* N} (h : s.EqOn f g) :
     f = g :=
   eq_of_eqOn_top <| hs ▸ eqOn_closure h
 #align mul_hom.eq_of_eq_on_mdense MulHom.eq_of_eqOn_dense
 #align add_hom.eq_of_eq_on_mdense AddHom.eq_of_eqOn_dense
+-/
 
 end MulHom
 
@@ -582,6 +620,7 @@ namespace MulHom
 
 open Subsemigroup
 
+#print MulHom.ofDense /-
 /-- Let `s` be a subset of a semigroup `M` such that the closure of `s` is the whole semigroup.
 Then `mul_hom.of_mdense` defines a mul homomorphism from `M` asking for a proof
 of `f (x * y) = f x * f y` only for `y ∈ s`. -/
@@ -595,18 +634,21 @@ def ofDense {M N} [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : cl
       (fun y₁ y₂ h₁ h₂ x => by simp only [← mul_assoc, h₁, h₂]) x
 #align mul_hom.of_mdense MulHom.ofDense
 #align add_hom.of_mdense AddHom.ofDense
+-/
 
 /-- Let `s` be a subset of an additive semigroup `M` such that the closure of `s` is the whole
 semigroup.  Then `add_hom.of_mdense` defines an additive homomorphism from `M` asking for a proof
 of `f (x + y) = f x + f y` only for `y ∈ s`. -/
 add_decl_doc AddHom.ofDense
 
+#print MulHom.coe_ofDense /-
 @[simp, norm_cast, to_additive]
 theorem coe_ofDense [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : closure s = ⊤)
     (hmul) : (ofDense f hs hmul : M → N) = f :=
   rfl
 #align mul_hom.coe_of_mdense MulHom.coe_ofDense
 #align add_hom.coe_of_mdense AddHom.coe_ofDense
+-/
 
 end MulHom
 
Diff
@@ -341,7 +341,7 @@ instance [hn : Nonempty M] : Nontrivial (Subsemigroup M) :=
 /-- The `subsemigroup` generated by a set. -/
 @[to_additive "The `add_subsemigroup` generated by a set"]
 def closure (s : Set M) : Subsemigroup M :=
-  sInf { S | s ⊆ S }
+  sInf {S | s ⊆ S}
 #align subsemigroup.closure Subsemigroup.closure
 #align add_subsemigroup.closure AddSubsemigroup.closure
 -/
@@ -545,7 +545,7 @@ open Subsemigroup
 @[to_additive "The additive subsemigroup of elements `x : M` such that `f x = g x`"]
 def eqLocus (f g : M →ₙ* N) : Subsemigroup M
     where
-  carrier := { x | f x = g x }
+  carrier := {x | f x = g x}
   mul_mem' x y (hx : _ = _) (hy : _ = _) := by simp [*]
 #align mul_hom.eq_mlocus MulHom.eqLocus
 #align add_hom.eq_mlocus AddHom.eqLocus
Diff
@@ -109,7 +109,7 @@ namespace Subsemigroup
 
 @[to_additive]
 instance : SetLike (Subsemigroup M) M :=
-  ⟨Subsemigroup.carrier, fun p q h => by cases p <;> cases q <;> congr ⟩
+  ⟨Subsemigroup.carrier, fun p q h => by cases p <;> cases q <;> congr⟩
 
 @[to_additive]
 instance : MulMemClass (Subsemigroup M) M where mul_mem := Subsemigroup.mul_mem'
Diff
@@ -149,12 +149,6 @@ theorem coe_set_mk {s : Set M} (h_mul) : (mk s h_mul : Set M) = s :=
 #align add_subsemigroup.coe_set_mk AddSubsemigroup.coe_set_mk
 -/
 
-/- warning: subsemigroup.mk_le_mk -> Subsemigroup.mk_le_mk is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {t : Set.{u1} M} (h_mul : forall {a : M} {b : M}, (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) a s) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) b s) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) s)) (h_mul' : forall {a : M} {b : M}, (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) a t) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) b t) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) t)), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.mk.{u1} M _inst_1 s h_mul) (Subsemigroup.mk.{u1} M _inst_1 t h_mul')) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s t)
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {t : Set.{u1} M} (h_mul : forall {a : M} {b : M}, (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) a s) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) b s) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) s)) (h_mul' : forall {a : M} {b : M}, (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) a t) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) b t) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) t)), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.instPartialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)))) (Subsemigroup.mk.{u1} M _inst_1 s h_mul) (Subsemigroup.mk.{u1} M _inst_1 t h_mul')) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s t)
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mk_le_mk Subsemigroup.mk_le_mkₓ'. -/
 @[simp, to_additive]
 theorem mk_le_mk {s t : Set M} (h_mul) (h_mul') : mk s h_mul ≤ mk t h_mul' ↔ s ⊆ t :=
   Iff.rfl
@@ -265,24 +259,12 @@ instance : Inf (Subsemigroup M) :=
     { carrier := S₁ ∩ S₂
       mul_mem' := fun _ _ ⟨hx, hx'⟩ ⟨hy, hy'⟩ => ⟨S₁.mul_mem hx hy, S₂.mul_mem hx' hy'⟩ }⟩
 
-/- warning: subsemigroup.coe_inf -> Subsemigroup.coe_inf is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (p : Subsemigroup.{u1} M _inst_1) (p' : Subsemigroup.{u1} M _inst_1), Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) p p')) (Inter.inter.{u1} (Set.{u1} M) (Set.hasInter.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) p) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) p'))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (p : Subsemigroup.{u1} M _inst_1) (p' : Subsemigroup.{u1} M _inst_1), Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSubsemigroup.{u1} M _inst_1) p p')) (Inter.inter.{u1} (Set.{u1} M) (Set.instInterSet.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) p) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) p'))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_inf Subsemigroup.coe_infₓ'. -/
 @[simp, to_additive]
 theorem coe_inf (p p' : Subsemigroup M) : ((p ⊓ p' : Subsemigroup M) : Set M) = p ∩ p' :=
   rfl
 #align subsemigroup.coe_inf Subsemigroup.coe_inf
 #align add_subsemigroup.coe_inf AddSubsemigroup.coe_inf
 
-/- warning: subsemigroup.mem_inf -> Subsemigroup.mem_inf is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {p : Subsemigroup.{u1} M _inst_1} {p' : Subsemigroup.{u1} M _inst_1} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) p p')) (And (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p) (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p'))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {p : Subsemigroup.{u1} M _inst_1} {p' : Subsemigroup.{u1} M _inst_1} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSubsemigroup.{u1} M _inst_1) p p')) (And (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p) (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p'))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_inf Subsemigroup.mem_infₓ'. -/
 @[simp, to_additive]
 theorem mem_inf {p p' : Subsemigroup M} {x : M} : x ∈ p ⊓ p' ↔ x ∈ p ∧ x ∈ p' :=
   Iff.rfl
@@ -297,48 +279,24 @@ instance : InfSet (Subsemigroup M) :=
         Set.mem_biInter fun i h =>
           i.mul_mem (by apply Set.mem_iInter₂.1 hx i h) (by apply Set.mem_iInter₂.1 hy i h) }⟩
 
-/- warning: subsemigroup.coe_Inf -> Subsemigroup.coe_sInf is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (S : Set.{u1} (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) S)) (Set.iInter.{u1, succ u1} M (Subsemigroup.{u1} M _inst_1) (fun (s : Subsemigroup.{u1} M _inst_1) => Set.iInter.{u1, 0} M (Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) s S) (fun (H : Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) s S) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) s)))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (S : Set.{u1} (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) S)) (Set.iInter.{u1, succ u1} M (Subsemigroup.{u1} M _inst_1) (fun (s : Subsemigroup.{u1} M _inst_1) => Set.iInter.{u1, 0} M (Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) s S) (fun (H : Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) s S) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) s)))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_Inf Subsemigroup.coe_sInfₓ'. -/
 @[simp, norm_cast, to_additive]
 theorem coe_sInf (S : Set (Subsemigroup M)) : ((sInf S : Subsemigroup M) : Set M) = ⋂ s ∈ S, ↑s :=
   rfl
 #align subsemigroup.coe_Inf Subsemigroup.coe_sInf
 #align add_subsemigroup.coe_Inf AddSubsemigroup.coe_sInf
 
-/- warning: subsemigroup.mem_Inf -> Subsemigroup.mem_sInf is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {S : Set.{u1} (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) S)) (forall (p : Subsemigroup.{u1} M _inst_1), (Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) p S) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {S : Set.{u1} (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) S)) (forall (p : Subsemigroup.{u1} M _inst_1), (Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) p S) -> (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_Inf Subsemigroup.mem_sInfₓ'. -/
 @[to_additive]
 theorem mem_sInf {S : Set (Subsemigroup M)} {x : M} : x ∈ sInf S ↔ ∀ p ∈ S, x ∈ p :=
   Set.mem_iInter₂
 #align subsemigroup.mem_Inf Subsemigroup.mem_sInf
 #align add_subsemigroup.mem_Inf AddSubsemigroup.mem_sInf
 
-/- warning: subsemigroup.mem_infi -> Subsemigroup.mem_iInf is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) ι (fun (i : ι) => S i))) (forall (i : ι), Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (S i))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) ι (fun (i : ι) => S i))) (forall (i : ι), Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (S i))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_infi Subsemigroup.mem_iInfₓ'. -/
 @[to_additive]
 theorem mem_iInf {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
   simp only [iInf, mem_Inf, Set.forall_range_iff]
 #align subsemigroup.mem_infi Subsemigroup.mem_iInf
 #align add_subsemigroup.mem_infi AddSubsemigroup.mem_iInf
 
-/- warning: subsemigroup.coe_infi -> Subsemigroup.coe_iInf is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)}, Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) ι (fun (i : ι) => S i))) (Set.iInter.{u1, u2} M ι (fun (i : ι) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (S i)))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)}, Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) ι (fun (i : ι) => S i))) (Set.iInter.{u1, u2} M ι (fun (i : ι) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (S i)))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_infi Subsemigroup.coe_iInfₓ'. -/
 @[simp, norm_cast, to_additive]
 theorem coe_iInf {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
   simp only [iInf, coe_Inf, Set.biInter_range]
@@ -416,12 +374,6 @@ variable {S}
 
 open Set
 
-/- warning: subsemigroup.closure_le -> Subsemigroup.closure_le is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) S) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (Subsemigroup.closure.{u1} M _inst_1 s) S) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) S))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_le Subsemigroup.closure_leₓ'. -/
 /-- A subsemigroup `S` includes `closure s` if and only if it includes `s`. -/
 @[simp,
   to_additive "An additive subsemigroup `S` includes `closure s`\nif and only if it includes `s`"]
@@ -430,12 +382,6 @@ theorem closure_le : closure s ≤ S ↔ s ⊆ S :=
 #align subsemigroup.closure_le Subsemigroup.closure_le
 #align add_subsemigroup.closure_le AddSubsemigroup.closure_le
 
-/- warning: subsemigroup.closure_mono -> Subsemigroup.closure_mono is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {{s : Set.{u1} M}} {{t : Set.{u1} M}}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s t) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {{s : Set.{u1} M}} {{t : Set.{u1} M}}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s t) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_mono Subsemigroup.closure_monoₓ'. -/
 /-- subsemigroup closure of a set is monotone in its argument: if `s ⊆ t`,
 then `closure s ≤ closure t`. -/
 @[to_additive
@@ -445,12 +391,6 @@ theorem closure_mono ⦃s t : Set M⦄ (h : s ⊆ t) : closure s ≤ closure t :
 #align subsemigroup.closure_mono Subsemigroup.closure_mono
 #align add_subsemigroup.closure_mono AddSubsemigroup.closure_mono
 
-/- warning: subsemigroup.closure_eq_of_le -> Subsemigroup.closure_eq_of_le is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S)) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S (Subsemigroup.closure.{u1} M _inst_1 s)) -> (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) S)
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) S)) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) S (Subsemigroup.closure.{u1} M _inst_1 s)) -> (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) S)
-Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_eq_of_le Subsemigroup.closure_eq_of_leₓ'. -/
 @[to_additive]
 theorem closure_eq_of_le (h₁ : s ⊆ S) (h₂ : S ≤ closure s) : closure s = S :=
   le_antisymm (closure_le.2 h₁) h₂
@@ -520,12 +460,6 @@ theorem dense_induction {p : M → Prop} (x : M) {s : Set M} (hs : closure s = 
 
 variable (M)
 
-/- warning: subsemigroup.gi -> Subsemigroup.gi is a dubious translation:
-lean 3 declaration is
-  forall (M : Type.{u1}) [_inst_1 : Mul.{u1} M], GaloisInsertion.{u1, u1} (Set.{u1} M) (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Set.{u1} M) (CompleteSemilatticeInf.toPartialOrder.{u1} (Set.{u1} M) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Set.{u1} M) (Order.Coframe.toCompleteLattice.{u1} (Set.{u1} M) (CompleteDistribLattice.toCoframe.{u1} (Set.{u1} M) (CompleteBooleanAlgebra.toCompleteDistribLattice.{u1} (Set.{u1} M) (Set.completeBooleanAlgebra.{u1} M))))))) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1))) (Subsemigroup.closure.{u1} M _inst_1) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))))
-but is expected to have type
-  forall (M : Type.{u1}) [_inst_1 : Mul.{u1} M], GaloisInsertion.{u1, u1} (Set.{u1} M) (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Set.{u1} M) (CompleteSemilatticeInf.toPartialOrder.{u1} (Set.{u1} M) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Set.{u1} M) (Order.Coframe.toCompleteLattice.{u1} (Set.{u1} M) (CompleteDistribLattice.toCoframe.{u1} (Set.{u1} M) (CompleteBooleanAlgebra.toCompleteDistribLattice.{u1} (Set.{u1} M) (Set.instCompleteBooleanAlgebraSet.{u1} M))))))) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.gi Subsemigroup.giₓ'. -/
 /-- `closure` forms a Galois insertion with the coercion to set. -/
 @[to_additive "`closure` forms a Galois insertion with the coercion to set."]
 protected def gi : GaloisInsertion (@closure M _) coe
@@ -564,48 +498,24 @@ theorem closure_univ : closure (univ : Set M) = ⊤ :=
 #align add_subsemigroup.closure_univ AddSubsemigroup.closure_univ
 -/
 
-/- warning: subsemigroup.closure_union -> Subsemigroup.closure_union is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (s : Set.{u1} M) (t : Set.{u1} M), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Union.union.{u1} (Set.{u1} M) (Set.hasUnion.{u1} M) s t)) (Sup.sup.{u1} (Subsemigroup.{u1} M _inst_1) (SemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (Lattice.toSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toLattice.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (s : Set.{u1} M) (t : Set.{u1} M), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Union.union.{u1} (Set.{u1} M) (Set.instUnionSet.{u1} M) s t)) (Sup.sup.{u1} (Subsemigroup.{u1} M _inst_1) (SemilatticeSup.toSup.{u1} (Subsemigroup.{u1} M _inst_1) (Lattice.toSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toLattice.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_union Subsemigroup.closure_unionₓ'. -/
 @[to_additive]
 theorem closure_union (s t : Set M) : closure (s ∪ t) = closure s ⊔ closure t :=
   (Subsemigroup.gi M).gc.l_sup
 #align subsemigroup.closure_union Subsemigroup.closure_union
 #align add_subsemigroup.closure_union AddSubsemigroup.closure_union
 
-/- warning: subsemigroup.closure_Union -> Subsemigroup.closure_iUnion is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (s : ι -> (Set.{u1} M)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => s i))) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => Subsemigroup.closure.{u1} M _inst_1 (s i)))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (s : ι -> (Set.{u1} M)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => s i))) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => Subsemigroup.closure.{u1} M _inst_1 (s i)))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_Union Subsemigroup.closure_iUnionₓ'. -/
 @[to_additive]
 theorem closure_iUnion {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, closure (s i) :=
   (Subsemigroup.gi M).gc.l_iSup
 #align subsemigroup.closure_Union Subsemigroup.closure_iUnion
 #align add_subsemigroup.closure_Union AddSubsemigroup.closure_iUnion
 
-/- warning: subsemigroup.closure_singleton_le_iff_mem -> Subsemigroup.closure_singleton_le_iff_mem is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (m : M) (p : Subsemigroup.{u1} M _inst_1), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 (Singleton.singleton.{u1, u1} M (Set.{u1} M) (Set.hasSingleton.{u1} M) m)) p) (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m p)
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (m : M) (p : Subsemigroup.{u1} M _inst_1), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (Subsemigroup.closure.{u1} M _inst_1 (Singleton.singleton.{u1, u1} M (Set.{u1} M) (Set.instSingletonSet.{u1} M) m)) p) (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m p)
-Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_singleton_le_iff_mem Subsemigroup.closure_singleton_le_iff_memₓ'. -/
 @[simp, to_additive]
 theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m} ≤ p ↔ m ∈ p := by
   rw [closure_le, singleton_subset_iff, SetLike.mem_coe]
 #align subsemigroup.closure_singleton_le_iff_mem Subsemigroup.closure_singleton_le_iff_mem
 #align add_subsemigroup.closure_singleton_le_iff_mem AddSubsemigroup.closure_singleton_le_iff_mem
 
-/- warning: subsemigroup.mem_supr -> Subsemigroup.mem_iSup is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i) N) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m N))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (p i) N) -> (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m N))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_supr Subsemigroup.mem_iSupₓ'. -/
 @[to_additive]
 theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
     (m ∈ ⨆ i, p i) ↔ ∀ N, (∀ i, p i ≤ N) → m ∈ N :=
@@ -615,12 +525,6 @@ theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
 #align subsemigroup.mem_supr Subsemigroup.mem_iSup
 #align add_subsemigroup.mem_supr AddSubsemigroup.mem_iSup
 
-/- warning: subsemigroup.supr_eq_closure -> Subsemigroup.iSup_eq_closure is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i)) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i))))
-but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => p i)) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (p i))))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.supr_eq_closure Subsemigroup.iSup_eq_closureₓ'. -/
 @[to_additive]
 theorem iSup_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
     (⨆ i, p i) = Subsemigroup.closure (⋃ i, (p i : Set M)) := by
@@ -647,12 +551,6 @@ def eqLocus (f g : M →ₙ* N) : Subsemigroup M
 #align add_hom.eq_mlocus AddHom.eqLocus
 -/
 
-/- warning: mul_hom.eq_on_mclosure -> MulHom.eqOn_closure is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3} {s : Set.{u1} M}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s)))
-but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3} {s : Set.{u2} M}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s)))
-Case conversion may be inaccurate. Consider using '#align mul_hom.eq_on_mclosure MulHom.eqOn_closureₓ'. -/
 /-- If two mul homomorphisms are equal on a set, then they are equal on its subsemigroup closure. -/
 @[to_additive
       "If two add homomorphisms are equal on a set,\nthen they are equal on its additive subsemigroup closure."]
@@ -661,24 +559,12 @@ theorem eqOn_closure {f g : M →ₙ* N} {s : Set M} (h : Set.EqOn f g s) : Set.
 #align mul_hom.eq_on_mclosure MulHom.eqOn_closure
 #align add_hom.eq_on_mclosure AddHom.eqOn_closure
 
-/- warning: mul_hom.eq_of_eq_on_mtop -> MulHom.eq_of_eqOn_top is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g)
-but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g)
-Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eqOn_topₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup M)) : f = g :=
   ext fun x => h trivial
 #align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eqOn_top
 #align add_hom.eq_of_eq_on_mtop AddHom.eq_of_eqOn_top
 
-/- warning: mul_hom.eq_of_eq_on_mdense -> MulHom.eq_of_eqOn_dense is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {s : Set.{u1} M}, (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1))) -> (forall {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g))
-but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {s : Set.{u2} M}, (Eq.{succ u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1))) -> (forall {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g))
-Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mdense MulHom.eq_of_eqOn_denseₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_dense {s : Set M} (hs : closure s = ⊤) {f g : M →ₙ* N} (h : s.EqOn f g) :
     f = g :=
@@ -696,12 +582,6 @@ namespace MulHom
 
 open Subsemigroup
 
-/- warning: mul_hom.of_mdense -> MulHom.ofDense is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Semigroup.{u1} M] [_inst_2 : Semigroup.{u2} N] {s : Set.{u1} M} (f : M -> N), (Eq.{succ u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.closure.{u1} M (Semigroup.toHasMul.{u1} M _inst_1) s) (Top.top.{u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.hasTop.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)))) -> (forall (x : M) (y : M), (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) y s) -> (Eq.{succ u2} N (f (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) x y)) (HMul.hMul.{u2, u2, u2} N N N (instHMul.{u2} N (Semigroup.toHasMul.{u2} N _inst_2)) (f x) (f y)))) -> (MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2))
-but is expected to have type
-  forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Semigroup.{u1} M] [_inst_2 : Semigroup.{u2} N] {s : Set.{u1} M} (f : M -> N), (Eq.{succ u1} (Subsemigroup.{u1} M (Semigroup.toMul.{u1} M _inst_1)) (Subsemigroup.closure.{u1} M (Semigroup.toMul.{u1} M _inst_1) s) (Top.top.{u1} (Subsemigroup.{u1} M (Semigroup.toMul.{u1} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u1} M (Semigroup.toMul.{u1} M _inst_1)))) -> (forall (x : M) (y : M), (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) y s) -> (Eq.{succ u2} N (f (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M (Semigroup.toMul.{u1} M _inst_1)) x y)) (HMul.hMul.{u2, u2, u2} N N N (instHMul.{u2} N (Semigroup.toMul.{u2} N _inst_2)) (f x) (f y)))) -> (MulHom.{u1, u2} M N (Semigroup.toMul.{u1} M _inst_1) (Semigroup.toMul.{u2} N _inst_2))
-Case conversion may be inaccurate. Consider using '#align mul_hom.of_mdense MulHom.ofDenseₓ'. -/
 /-- Let `s` be a subset of a semigroup `M` such that the closure of `s` is the whole semigroup.
 Then `mul_hom.of_mdense` defines a mul homomorphism from `M` asking for a proof
 of `f (x * y) = f x * f y` only for `y ∈ s`. -/
@@ -721,12 +601,6 @@ semigroup.  Then `add_hom.of_mdense` defines an additive homomorphism from `M` a
 of `f (x + y) = f x + f y` only for `y ∈ s`. -/
 add_decl_doc AddHom.ofDense
 
-/- warning: mul_hom.coe_of_mdense -> MulHom.coe_ofDense is a dubious translation:
-lean 3 declaration is
-  forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Semigroup.{u1} M] [_inst_2 : Semigroup.{u2} N] {s : Set.{u1} M} (f : M -> N) (hs : Eq.{succ u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.closure.{u1} M (Semigroup.toHasMul.{u1} M _inst_1) s) (Top.top.{u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.hasTop.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) y s) -> (Eq.{succ u2} N (f (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) x y)) (HMul.hMul.{u2, u2, u2} N N N (instHMul.{u2} N (Semigroup.toHasMul.{u2} N _inst_2)) (f x) (f y)))), Eq.{max (succ u1) (succ u2)} ((fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) f
-but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Semigroup.{u2} M] [_inst_2 : Semigroup.{u1} N] {s : Set.{u2} M} (f : M -> N) (hs : Eq.{succ u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.closure.{u2} M (Semigroup.toMul.{u2} M _inst_1) s) (Top.top.{u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.mem.{u2, u2} M (Set.{u2} M) (Set.instMembershipSet.{u2} M) y s) -> (Eq.{succ u1} N (f (HMul.hMul.{u2, u2, u2} M M M (instHMul.{u2} M (Semigroup.toMul.{u2} M _inst_1)) x y)) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N _inst_2)) (f x) (f y)))), Eq.{max (succ u2) (succ u1)} (forall (a : M), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2) (MulHom.mulHomClass.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2))) (MulHom.ofDense.{u2, u1} M N _inst_1 _inst_2 s f hs hmul)) f
-Case conversion may be inaccurate. Consider using '#align mul_hom.coe_of_mdense MulHom.coe_ofDenseₓ'. -/
 @[simp, norm_cast, to_additive]
 theorem coe_ofDense [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : closure s = ⊤)
     (hmul) : (ofDense f hs hmul : M → N) = f :=
Diff
@@ -377,10 +377,7 @@ theorem subsingleton_of_subsingleton [Subsingleton (Subsemigroup M)] : Subsingle
 
 @[to_additive]
 instance [hn : Nonempty M] : Nontrivial (Subsemigroup M) :=
-  ⟨⟨⊥, ⊤, fun h => by
-      obtain ⟨x⟩ := id hn
-      refine' absurd (_ : x ∈ ⊥) not_mem_bot
-      simp [h]⟩⟩
+  ⟨⟨⊥, ⊤, fun h => by obtain ⟨x⟩ := id hn; refine' absurd (_ : x ∈ ⊥) not_mem_bot; simp [h]⟩⟩
 
 #print Subsemigroup.closure /-
 /-- The `subsemigroup` generated by a set. -/
Diff
@@ -654,7 +654,7 @@ def eqLocus (f g : M →ₙ* N) : Subsemigroup M
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3} {s : Set.{u1} M}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s)))
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3} {s : Set.{u2} M}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s)))
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3} {s : Set.{u2} M}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s)))
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_on_mclosure MulHom.eqOn_closureₓ'. -/
 /-- If two mul homomorphisms are equal on a set, then they are equal on its subsemigroup closure. -/
 @[to_additive
@@ -668,7 +668,7 @@ theorem eqOn_closure {f g : M →ₙ* N} {s : Set M} (h : Set.EqOn f g s) : Set.
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g)
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g)
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g)
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eqOn_topₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup M)) : f = g :=
@@ -680,7 +680,7 @@ theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {s : Set.{u1} M}, (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1))) -> (forall {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g))
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {s : Set.{u2} M}, (Eq.{succ u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1))) -> (forall {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g))
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {s : Set.{u2} M}, (Eq.{succ u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1))) -> (forall {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g))
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mdense MulHom.eq_of_eqOn_denseₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_dense {s : Set M} (hs : closure s = ⊤) {f g : M →ₙ* N} (h : s.EqOn f g) :
@@ -728,7 +728,7 @@ add_decl_doc AddHom.ofDense
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Semigroup.{u1} M] [_inst_2 : Semigroup.{u2} N] {s : Set.{u1} M} (f : M -> N) (hs : Eq.{succ u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.closure.{u1} M (Semigroup.toHasMul.{u1} M _inst_1) s) (Top.top.{u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.hasTop.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) y s) -> (Eq.{succ u2} N (f (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) x y)) (HMul.hMul.{u2, u2, u2} N N N (instHMul.{u2} N (Semigroup.toHasMul.{u2} N _inst_2)) (f x) (f y)))), Eq.{max (succ u1) (succ u2)} ((fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) f
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Semigroup.{u2} M] [_inst_2 : Semigroup.{u1} N] {s : Set.{u2} M} (f : M -> N) (hs : Eq.{succ u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.closure.{u2} M (Semigroup.toMul.{u2} M _inst_1) s) (Top.top.{u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.mem.{u2, u2} M (Set.{u2} M) (Set.instMembershipSet.{u2} M) y s) -> (Eq.{succ u1} N (f (HMul.hMul.{u2, u2, u2} M M M (instHMul.{u2} M (Semigroup.toMul.{u2} M _inst_1)) x y)) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N _inst_2)) (f x) (f y)))), Eq.{max (succ u2) (succ u1)} (forall (a : M), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2) (MulHom.mulHomClass.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2))) (MulHom.ofDense.{u2, u1} M N _inst_1 _inst_2 s f hs hmul)) f
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Semigroup.{u2} M] [_inst_2 : Semigroup.{u1} N] {s : Set.{u2} M} (f : M -> N) (hs : Eq.{succ u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.closure.{u2} M (Semigroup.toMul.{u2} M _inst_1) s) (Top.top.{u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.mem.{u2, u2} M (Set.{u2} M) (Set.instMembershipSet.{u2} M) y s) -> (Eq.{succ u1} N (f (HMul.hMul.{u2, u2, u2} M M M (instHMul.{u2} M (Semigroup.toMul.{u2} M _inst_1)) x y)) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N _inst_2)) (f x) (f y)))), Eq.{max (succ u2) (succ u1)} (forall (a : M), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2397 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2) (MulHom.mulHomClass.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2))) (MulHom.ofDense.{u2, u1} M N _inst_1 _inst_2 s f hs hmul)) f
 Case conversion may be inaccurate. Consider using '#align mul_hom.coe_of_mdense MulHom.coe_ofDenseₓ'. -/
 @[simp, norm_cast, to_additive]
 theorem coe_ofDense [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : closure s = ⊤)
Diff
@@ -151,7 +151,7 @@ theorem coe_set_mk {s : Set M} (h_mul) : (mk s h_mul : Set M) = s :=
 
 /- warning: subsemigroup.mk_le_mk -> Subsemigroup.mk_le_mk is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {t : Set.{u1} M} (h_mul : forall {a : M} {b : M}, (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) a s) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) b s) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) s)) (h_mul' : forall {a : M} {b : M}, (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) a t) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) b t) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) t)), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.mk.{u1} M _inst_1 s h_mul) (Subsemigroup.mk.{u1} M _inst_1 t h_mul')) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s t)
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {t : Set.{u1} M} (h_mul : forall {a : M} {b : M}, (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) a s) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) b s) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) s)) (h_mul' : forall {a : M} {b : M}, (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) a t) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) b t) -> (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) t)), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.mk.{u1} M _inst_1 s h_mul) (Subsemigroup.mk.{u1} M _inst_1 t h_mul')) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s t)
 but is expected to have type
   forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {t : Set.{u1} M} (h_mul : forall {a : M} {b : M}, (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) a s) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) b s) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) s)) (h_mul' : forall {a : M} {b : M}, (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) a t) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) b t) -> (Membership.mem.{u1, u1} M (Set.{u1} M) (Set.instMembershipSet.{u1} M) (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M _inst_1) a b) t)), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.instPartialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)))) (Subsemigroup.mk.{u1} M _inst_1 s h_mul) (Subsemigroup.mk.{u1} M _inst_1 t h_mul')) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s t)
 Case conversion may be inaccurate. Consider using '#align subsemigroup.mk_le_mk Subsemigroup.mk_le_mkₓ'. -/
@@ -421,7 +421,7 @@ open Set
 
 /- warning: subsemigroup.closure_le -> Subsemigroup.closure_le is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) S) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) S) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S))
 but is expected to have type
   forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (Subsemigroup.closure.{u1} M _inst_1 s) S) (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) S))
 Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_le Subsemigroup.closure_leₓ'. -/
@@ -435,7 +435,7 @@ theorem closure_le : closure s ≤ S ↔ s ⊆ S :=
 
 /- warning: subsemigroup.closure_mono -> Subsemigroup.closure_mono is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {{s : Set.{u1} M}} {{t : Set.{u1} M}}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s t) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {{s : Set.{u1} M}} {{t : Set.{u1} M}}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s t) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
 but is expected to have type
   forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {{s : Set.{u1} M}} {{t : Set.{u1} M}}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s t) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
 Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_mono Subsemigroup.closure_monoₓ'. -/
@@ -450,7 +450,7 @@ theorem closure_mono ⦃s t : Set M⦄ (h : s ⊆ t) : closure s ≤ closure t :
 
 /- warning: subsemigroup.closure_eq_of_le -> Subsemigroup.closure_eq_of_le is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S)) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S (Subsemigroup.closure.{u1} M _inst_1 s)) -> (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) S)
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.hasSubset.{u1} M) s ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S)) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) S (Subsemigroup.closure.{u1} M _inst_1 s)) -> (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) S)
 but is expected to have type
   forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {s : Set.{u1} M} {S : Subsemigroup.{u1} M _inst_1}, (HasSubset.Subset.{u1} (Set.{u1} M) (Set.instHasSubsetSet.{u1} M) s (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) S)) -> (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) S (Subsemigroup.closure.{u1} M _inst_1 s)) -> (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) S)
 Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_eq_of_le Subsemigroup.closure_eq_of_leₓ'. -/
@@ -593,7 +593,7 @@ theorem closure_iUnion {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, c
 
 /- warning: subsemigroup.closure_singleton_le_iff_mem -> Subsemigroup.closure_singleton_le_iff_mem is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (m : M) (p : Subsemigroup.{u1} M _inst_1), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 (Singleton.singleton.{u1, u1} M (Set.{u1} M) (Set.hasSingleton.{u1} M) m)) p) (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m p)
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (m : M) (p : Subsemigroup.{u1} M _inst_1), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 (Singleton.singleton.{u1, u1} M (Set.{u1} M) (Set.hasSingleton.{u1} M) m)) p) (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m p)
 but is expected to have type
   forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (m : M) (p : Subsemigroup.{u1} M _inst_1), Iff (LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (Subsemigroup.closure.{u1} M _inst_1 (Singleton.singleton.{u1, u1} M (Set.{u1} M) (Set.instSingletonSet.{u1} M) m)) p) (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m p)
 Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_singleton_le_iff_mem Subsemigroup.closure_singleton_le_iff_memₓ'. -/
@@ -605,7 +605,7 @@ theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m}
 
 /- warning: subsemigroup.mem_supr -> Subsemigroup.mem_iSup is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i) N) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m N))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toHasLe.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i) N) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m N))
 but is expected to have type
   forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (p i) N) -> (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m N))
 Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_supr Subsemigroup.mem_iSupₓ'. -/
Diff
@@ -294,56 +294,56 @@ instance : InfSet (Subsemigroup M) :=
   ⟨fun s =>
     { carrier := ⋂ t ∈ s, ↑t
       mul_mem' := fun x y hx hy =>
-        Set.mem_binterᵢ fun i h =>
-          i.mul_mem (by apply Set.mem_interᵢ₂.1 hx i h) (by apply Set.mem_interᵢ₂.1 hy i h) }⟩
+        Set.mem_biInter fun i h =>
+          i.mul_mem (by apply Set.mem_iInter₂.1 hx i h) (by apply Set.mem_iInter₂.1 hy i h) }⟩
 
-/- warning: subsemigroup.coe_Inf -> Subsemigroup.coe_infₛ is a dubious translation:
+/- warning: subsemigroup.coe_Inf -> Subsemigroup.coe_sInf is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (S : Set.{u1} (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (InfSet.infₛ.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) S)) (Set.interᵢ.{u1, succ u1} M (Subsemigroup.{u1} M _inst_1) (fun (s : Subsemigroup.{u1} M _inst_1) => Set.interᵢ.{u1, 0} M (Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) s S) (fun (H : Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) s S) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) s)))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (S : Set.{u1} (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) S)) (Set.iInter.{u1, succ u1} M (Subsemigroup.{u1} M _inst_1) (fun (s : Subsemigroup.{u1} M _inst_1) => Set.iInter.{u1, 0} M (Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) s S) (fun (H : Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) s S) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) s)))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (S : Set.{u1} (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (InfSet.infₛ.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) S)) (Set.interᵢ.{u1, succ u1} M (Subsemigroup.{u1} M _inst_1) (fun (s : Subsemigroup.{u1} M _inst_1) => Set.interᵢ.{u1, 0} M (Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) s S) (fun (H : Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) s S) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) s)))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_Inf Subsemigroup.coe_infₛₓ'. -/
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (S : Set.{u1} (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) S)) (Set.iInter.{u1, succ u1} M (Subsemigroup.{u1} M _inst_1) (fun (s : Subsemigroup.{u1} M _inst_1) => Set.iInter.{u1, 0} M (Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) s S) (fun (H : Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) s S) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) s)))
+Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_Inf Subsemigroup.coe_sInfₓ'. -/
 @[simp, norm_cast, to_additive]
-theorem coe_infₛ (S : Set (Subsemigroup M)) : ((infₛ S : Subsemigroup M) : Set M) = ⋂ s ∈ S, ↑s :=
+theorem coe_sInf (S : Set (Subsemigroup M)) : ((sInf S : Subsemigroup M) : Set M) = ⋂ s ∈ S, ↑s :=
   rfl
-#align subsemigroup.coe_Inf Subsemigroup.coe_infₛ
-#align add_subsemigroup.coe_Inf AddSubsemigroup.coe_infₛ
+#align subsemigroup.coe_Inf Subsemigroup.coe_sInf
+#align add_subsemigroup.coe_Inf AddSubsemigroup.coe_sInf
 
-/- warning: subsemigroup.mem_Inf -> Subsemigroup.mem_infₛ is a dubious translation:
+/- warning: subsemigroup.mem_Inf -> Subsemigroup.mem_sInf is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {S : Set.{u1} (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (InfSet.infₛ.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) S)) (forall (p : Subsemigroup.{u1} M _inst_1), (Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) p S) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {S : Set.{u1} (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) S)) (forall (p : Subsemigroup.{u1} M _inst_1), (Membership.Mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.hasMem.{u1} (Subsemigroup.{u1} M _inst_1)) p S) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {S : Set.{u1} (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (InfSet.infₛ.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) S)) (forall (p : Subsemigroup.{u1} M _inst_1), (Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) p S) -> (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_Inf Subsemigroup.mem_infₛₓ'. -/
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {S : Set.{u1} (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (InfSet.sInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) S)) (forall (p : Subsemigroup.{u1} M _inst_1), (Membership.mem.{u1, u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} (Subsemigroup.{u1} M _inst_1)) (Set.instMembershipSet.{u1} (Subsemigroup.{u1} M _inst_1)) p S) -> (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p))
+Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_Inf Subsemigroup.mem_sInfₓ'. -/
 @[to_additive]
-theorem mem_infₛ {S : Set (Subsemigroup M)} {x : M} : x ∈ infₛ S ↔ ∀ p ∈ S, x ∈ p :=
-  Set.mem_interᵢ₂
-#align subsemigroup.mem_Inf Subsemigroup.mem_infₛ
-#align add_subsemigroup.mem_Inf AddSubsemigroup.mem_infₛ
+theorem mem_sInf {S : Set (Subsemigroup M)} {x : M} : x ∈ sInf S ↔ ∀ p ∈ S, x ∈ p :=
+  Set.mem_iInter₂
+#align subsemigroup.mem_Inf Subsemigroup.mem_sInf
+#align add_subsemigroup.mem_Inf AddSubsemigroup.mem_sInf
 
-/- warning: subsemigroup.mem_infi -> Subsemigroup.mem_infᵢ is a dubious translation:
+/- warning: subsemigroup.mem_infi -> Subsemigroup.mem_iInf is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (infᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) ι (fun (i : ι) => S i))) (forall (i : ι), Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (S i))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) ι (fun (i : ι) => S i))) (forall (i : ι), Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (S i))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (infᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) ι (fun (i : ι) => S i))) (forall (i : ι), Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (S i))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_infi Subsemigroup.mem_infᵢₓ'. -/
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) ι (fun (i : ι) => S i))) (forall (i : ι), Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (S i))
+Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_infi Subsemigroup.mem_iInfₓ'. -/
 @[to_additive]
-theorem mem_infᵢ {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
-  simp only [infᵢ, mem_Inf, Set.forall_range_iff]
-#align subsemigroup.mem_infi Subsemigroup.mem_infᵢ
-#align add_subsemigroup.mem_infi AddSubsemigroup.mem_infᵢ
+theorem mem_iInf {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
+  simp only [iInf, mem_Inf, Set.forall_range_iff]
+#align subsemigroup.mem_infi Subsemigroup.mem_iInf
+#align add_subsemigroup.mem_infi AddSubsemigroup.mem_iInf
 
-/- warning: subsemigroup.coe_infi -> Subsemigroup.coe_infᵢ is a dubious translation:
+/- warning: subsemigroup.coe_infi -> Subsemigroup.coe_iInf is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)}, Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (infᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) ι (fun (i : ι) => S i))) (Set.interᵢ.{u1, u2} M ι (fun (i : ι) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (S i)))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)}, Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) ι (fun (i : ι) => S i))) (Set.iInter.{u1, u2} M ι (fun (i : ι) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (S i)))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)}, Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (infᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) ι (fun (i : ι) => S i))) (Set.interᵢ.{u1, u2} M ι (fun (i : ι) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (S i)))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_infi Subsemigroup.coe_infᵢₓ'. -/
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} {S : ι -> (Subsemigroup.{u1} M _inst_1)}, Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (iInf.{u1, u2} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSetSubsemigroup.{u1} M _inst_1) ι (fun (i : ι) => S i))) (Set.iInter.{u1, u2} M ι (fun (i : ι) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (S i)))
+Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_infi Subsemigroup.coe_iInfₓ'. -/
 @[simp, norm_cast, to_additive]
-theorem coe_infᵢ {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
-  simp only [infᵢ, coe_Inf, Set.binterᵢ_range]
-#align subsemigroup.coe_infi Subsemigroup.coe_infᵢ
-#align add_subsemigroup.coe_infi AddSubsemigroup.coe_infᵢ
+theorem coe_iInf {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
+  simp only [iInf, coe_Inf, Set.biInter_range]
+#align subsemigroup.coe_infi Subsemigroup.coe_iInf
+#align add_subsemigroup.coe_infi AddSubsemigroup.coe_iInf
 
 /-- subsemigroups of a monoid form a complete lattice. -/
 @[to_additive "The `add_subsemigroup`s of an `add_monoid` form a complete lattice."]
@@ -351,7 +351,7 @@ instance : CompleteLattice (Subsemigroup M) :=
   {
     completeLatticeOfInf (Subsemigroup M) fun s =>
       IsGLB.of_image (fun S T => show (S : Set M) ≤ T ↔ S ≤ T from SetLike.coe_subset_coe)
-        isGLB_binfᵢ with
+        isGLB_biInf with
     le := (· ≤ ·)
     lt := (· < ·)
     bot := ⊥
@@ -359,7 +359,7 @@ instance : CompleteLattice (Subsemigroup M) :=
     top := ⊤
     le_top := fun S x hx => mem_top x
     inf := (· ⊓ ·)
-    infₛ := InfSet.infₛ
+    sInf := InfSet.sInf
     le_inf := fun a b c ha hb x hx => ⟨ha hx, hb hx⟩
     inf_le_left := fun a b x => And.left
     inf_le_right := fun a b x => And.right }
@@ -386,7 +386,7 @@ instance [hn : Nonempty M] : Nontrivial (Subsemigroup M) :=
 /-- The `subsemigroup` generated by a set. -/
 @[to_additive "The `add_subsemigroup` generated by a set"]
 def closure (s : Set M) : Subsemigroup M :=
-  infₛ { S | s ⊆ S }
+  sInf { S | s ⊆ S }
 #align subsemigroup.closure Subsemigroup.closure
 #align add_subsemigroup.closure AddSubsemigroup.closure
 -/
@@ -394,7 +394,7 @@ def closure (s : Set M) : Subsemigroup M :=
 #print Subsemigroup.mem_closure /-
 @[to_additive]
 theorem mem_closure {x : M} : x ∈ closure s ↔ ∀ S : Subsemigroup M, s ⊆ S → x ∈ S :=
-  mem_infₛ
+  mem_sInf
 #align subsemigroup.mem_closure Subsemigroup.mem_closure
 #align add_subsemigroup.mem_closure AddSubsemigroup.mem_closure
 -/
@@ -429,7 +429,7 @@ Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_l
 @[simp,
   to_additive "An additive subsemigroup `S` includes `closure s`\nif and only if it includes `s`"]
 theorem closure_le : closure s ≤ S ↔ s ⊆ S :=
-  ⟨Subset.trans subset_closure, fun h => infₛ_le h⟩
+  ⟨Subset.trans subset_closure, fun h => sInf_le h⟩
 #align subsemigroup.closure_le Subsemigroup.closure_le
 #align add_subsemigroup.closure_le AddSubsemigroup.closure_le
 
@@ -579,17 +579,17 @@ theorem closure_union (s t : Set M) : closure (s ∪ t) = closure s ⊔ closure
 #align subsemigroup.closure_union Subsemigroup.closure_union
 #align add_subsemigroup.closure_union AddSubsemigroup.closure_union
 
-/- warning: subsemigroup.closure_Union -> Subsemigroup.closure_unionᵢ is a dubious translation:
+/- warning: subsemigroup.closure_Union -> Subsemigroup.closure_iUnion is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (s : ι -> (Set.{u1} M)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Set.unionᵢ.{u1, u2} M ι (fun (i : ι) => s i))) (supᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => Subsemigroup.closure.{u1} M _inst_1 (s i)))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (s : ι -> (Set.{u1} M)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => s i))) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => Subsemigroup.closure.{u1} M _inst_1 (s i)))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (s : ι -> (Set.{u1} M)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Set.unionᵢ.{u1, u2} M ι (fun (i : ι) => s i))) (supᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => Subsemigroup.closure.{u1} M _inst_1 (s i)))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_Union Subsemigroup.closure_unionᵢₓ'. -/
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (s : ι -> (Set.{u1} M)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => s i))) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => Subsemigroup.closure.{u1} M _inst_1 (s i)))
+Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_Union Subsemigroup.closure_iUnionₓ'. -/
 @[to_additive]
-theorem closure_unionᵢ {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, closure (s i) :=
-  (Subsemigroup.gi M).gc.l_supᵢ
-#align subsemigroup.closure_Union Subsemigroup.closure_unionᵢ
-#align add_subsemigroup.closure_Union AddSubsemigroup.closure_unionᵢ
+theorem closure_iUnion {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, closure (s i) :=
+  (Subsemigroup.gi M).gc.l_iSup
+#align subsemigroup.closure_Union Subsemigroup.closure_iUnion
+#align add_subsemigroup.closure_Union AddSubsemigroup.closure_iUnion
 
 /- warning: subsemigroup.closure_singleton_le_iff_mem -> Subsemigroup.closure_singleton_le_iff_mem is a dubious translation:
 lean 3 declaration is
@@ -603,33 +603,33 @@ theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m}
 #align subsemigroup.closure_singleton_le_iff_mem Subsemigroup.closure_singleton_le_iff_mem
 #align add_subsemigroup.closure_singleton_le_iff_mem AddSubsemigroup.closure_singleton_le_iff_mem
 
-/- warning: subsemigroup.mem_supr -> Subsemigroup.mem_supᵢ is a dubious translation:
+/- warning: subsemigroup.mem_supr -> Subsemigroup.mem_iSup is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m (supᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i) N) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m N))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (SetLike.partialOrder.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i) N) -> (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) m N))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m (supᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (p i) N) -> (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m N))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_supr Subsemigroup.mem_supᵢₓ'. -/
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)) {m : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => p i))) (forall (N : Subsemigroup.{u1} M _inst_1), (forall (i : ι), LE.le.{u1} (Subsemigroup.{u1} M _inst_1) (Preorder.toLE.{u1} (Subsemigroup.{u1} M _inst_1) (PartialOrder.toPreorder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeInf.toPartialOrder.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeInf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1))))) (p i) N) -> (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) m N))
+Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_supr Subsemigroup.mem_iSupₓ'. -/
 @[to_additive]
-theorem mem_supᵢ {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
+theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
     (m ∈ ⨆ i, p i) ↔ ∀ N, (∀ i, p i ≤ N) → m ∈ N :=
   by
-  rw [← closure_singleton_le_iff_mem, le_supᵢ_iff]
+  rw [← closure_singleton_le_iff_mem, le_iSup_iff]
   simp only [closure_singleton_le_iff_mem]
-#align subsemigroup.mem_supr Subsemigroup.mem_supᵢ
-#align add_subsemigroup.mem_supr AddSubsemigroup.mem_supᵢ
+#align subsemigroup.mem_supr Subsemigroup.mem_iSup
+#align add_subsemigroup.mem_supr AddSubsemigroup.mem_iSup
 
-/- warning: subsemigroup.supr_eq_closure -> Subsemigroup.supᵢ_eq_closure is a dubious translation:
+/- warning: subsemigroup.supr_eq_closure -> Subsemigroup.iSup_eq_closure is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (supᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i)) (Subsemigroup.closure.{u1} M _inst_1 (Set.unionᵢ.{u1, u2} M ι (fun (i : ι) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i))))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteSemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toCompleteSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1))) ι (fun (i : ι) => p i)) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => (fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (p i))))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (supᵢ.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => p i)) (Subsemigroup.closure.{u1} M _inst_1 (Set.unionᵢ.{u1, u2} M ι (fun (i : ι) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (p i))))
-Case conversion may be inaccurate. Consider using '#align subsemigroup.supr_eq_closure Subsemigroup.supᵢ_eq_closureₓ'. -/
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {ι : Sort.{u2}} (p : ι -> (Subsemigroup.{u1} M _inst_1)), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (iSup.{u1, u2} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toSupSet.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)) ι (fun (i : ι) => p i)) (Subsemigroup.closure.{u1} M _inst_1 (Set.iUnion.{u1, u2} M ι (fun (i : ι) => SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (p i))))
+Case conversion may be inaccurate. Consider using '#align subsemigroup.supr_eq_closure Subsemigroup.iSup_eq_closureₓ'. -/
 @[to_additive]
-theorem supᵢ_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
+theorem iSup_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
     (⨆ i, p i) = Subsemigroup.closure (⋃ i, (p i : Set M)) := by
-  simp_rw [Subsemigroup.closure_unionᵢ, Subsemigroup.closure_eq]
-#align subsemigroup.supr_eq_closure Subsemigroup.supᵢ_eq_closure
-#align add_subsemigroup.supr_eq_closure AddSubsemigroup.supᵢ_eq_closure
+  simp_rw [Subsemigroup.closure_iUnion, Subsemigroup.closure_eq]
+#align subsemigroup.supr_eq_closure Subsemigroup.iSup_eq_closure
+#align add_subsemigroup.supr_eq_closure AddSubsemigroup.iSup_eq_closure
 
 end Subsemigroup
 
Diff
@@ -654,7 +654,7 @@ def eqLocus (f g : M →ₙ* N) : Subsemigroup M
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3} {s : Set.{u1} M}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s)))
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3} {s : Set.{u2} M}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s)))
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3} {s : Set.{u2} M}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s)))
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_on_mclosure MulHom.eqOn_closureₓ'. -/
 /-- If two mul homomorphisms are equal on a set, then they are equal on its subsemigroup closure. -/
 @[to_additive
@@ -668,7 +668,7 @@ theorem eqOn_closure {f g : M →ₙ* N} {s : Set M} (h : Set.EqOn f g s) : Set.
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g)
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g)
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g)
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eqOn_topₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup M)) : f = g :=
@@ -680,7 +680,7 @@ theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {s : Set.{u1} M}, (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1))) -> (forall {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g))
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {s : Set.{u2} M}, (Eq.{succ u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1))) -> (forall {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g))
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {s : Set.{u2} M}, (Eq.{succ u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1))) -> (forall {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g))
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mdense MulHom.eq_of_eqOn_denseₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_dense {s : Set M} (hs : closure s = ⊤) {f g : M →ₙ* N} (h : s.EqOn f g) :
@@ -728,7 +728,7 @@ add_decl_doc AddHom.ofDense
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Semigroup.{u1} M] [_inst_2 : Semigroup.{u2} N] {s : Set.{u1} M} (f : M -> N) (hs : Eq.{succ u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.closure.{u1} M (Semigroup.toHasMul.{u1} M _inst_1) s) (Top.top.{u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.hasTop.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) y s) -> (Eq.{succ u2} N (f (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) x y)) (HMul.hMul.{u2, u2, u2} N N N (instHMul.{u2} N (Semigroup.toHasMul.{u2} N _inst_2)) (f x) (f y)))), Eq.{max (succ u1) (succ u2)} ((fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) f
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Semigroup.{u2} M] [_inst_2 : Semigroup.{u1} N] {s : Set.{u2} M} (f : M -> N) (hs : Eq.{succ u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.closure.{u2} M (Semigroup.toMul.{u2} M _inst_1) s) (Top.top.{u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.mem.{u2, u2} M (Set.{u2} M) (Set.instMembershipSet.{u2} M) y s) -> (Eq.{succ u1} N (f (HMul.hMul.{u2, u2, u2} M M M (instHMul.{u2} M (Semigroup.toMul.{u2} M _inst_1)) x y)) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N _inst_2)) (f x) (f y)))), Eq.{max (succ u2) (succ u1)} (forall (a : M), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2) (MulHom.mulHomClass.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2))) (MulHom.ofDense.{u2, u1} M N _inst_1 _inst_2 s f hs hmul)) f
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Semigroup.{u2} M] [_inst_2 : Semigroup.{u1} N] {s : Set.{u2} M} (f : M -> N) (hs : Eq.{succ u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.closure.{u2} M (Semigroup.toMul.{u2} M _inst_1) s) (Top.top.{u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.mem.{u2, u2} M (Set.{u2} M) (Set.instMembershipSet.{u2} M) y s) -> (Eq.{succ u1} N (f (HMul.hMul.{u2, u2, u2} M M M (instHMul.{u2} M (Semigroup.toMul.{u2} M _inst_1)) x y)) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N _inst_2)) (f x) (f y)))), Eq.{max (succ u2) (succ u1)} (forall (a : M), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2391 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2) (MulHom.mulHomClass.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2))) (MulHom.ofDense.{u2, u1} M N _inst_1 _inst_2 s f hs hmul)) f
 Case conversion may be inaccurate. Consider using '#align mul_hom.coe_of_mdense MulHom.coe_ofDenseₓ'. -/
 @[simp, norm_cast, to_additive]
 theorem coe_ofDense [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : closure s = ⊤)
Diff
@@ -114,14 +114,12 @@ instance : SetLike (Subsemigroup M) M :=
 @[to_additive]
 instance : MulMemClass (Subsemigroup M) M where mul_mem := Subsemigroup.mul_mem'
 
-#print Subsemigroup.Simps.coe /-
 /-- See Note [custom simps projection] -/
 @[to_additive " See Note [custom simps projection]"]
 def Simps.coe (S : Subsemigroup M) : Set M :=
   S
 #align subsemigroup.simps.coe Subsemigroup.Simps.coe
 #align add_subsemigroup.simps.coe AddSubsemigroup.Simps.coe
--/
 
 initialize_simps_projections Subsemigroup (carrier → coe)
 
@@ -656,7 +654,7 @@ def eqLocus (f g : M →ₙ* N) : Subsemigroup M
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3} {s : Set.{u1} M}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s)))
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3} {s : Set.{u2} M}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s)))
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3} {s : Set.{u2} M}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s)))
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_on_mclosure MulHom.eqOn_closureₓ'. -/
 /-- If two mul homomorphisms are equal on a set, then they are equal on its subsemigroup closure. -/
 @[to_additive
@@ -670,7 +668,7 @@ theorem eqOn_closure {f g : M →ₙ* N} {s : Set M} (h : Set.EqOn f g s) : Set.
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g)
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g)
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) (SetLike.coe.{u2, u2} (Subsemigroup.{u2} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u2} M _inst_1) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1)))) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g)
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eqOn_topₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup M)) : f = g :=
@@ -682,7 +680,7 @@ theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Mul.{u1} M] [_inst_3 : Mul.{u2} N] {s : Set.{u1} M}, (Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 s) (Top.top.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasTop.{u1} M _inst_1))) -> (forall {f : MulHom.{u1, u2} M N _inst_1 _inst_3} {g : MulHom.{u1, u2} M N _inst_1 _inst_3}, (Set.EqOn.{u1, u2} M N (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) f) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N _inst_1 _inst_3) (fun (_x : MulHom.{u1, u2} M N _inst_1 _inst_3) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N _inst_1 _inst_3) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u1, u2} M N _inst_1 _inst_3) f g))
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {s : Set.{u2} M}, (Eq.{succ u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1))) -> (forall {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g))
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Mul.{u2} M] [_inst_3 : Mul.{u1} N] {s : Set.{u2} M}, (Eq.{succ u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.closure.{u2} M _inst_1 s) (Top.top.{u2} (Subsemigroup.{u2} M _inst_1) (Subsemigroup.instTopSubsemigroup.{u2} M _inst_1))) -> (forall {f : MulHom.{u2, u1} M N _inst_1 _inst_3} {g : MulHom.{u2, u1} M N _inst_1 _inst_3}, (Set.EqOn.{u2, u1} M N (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) f) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N _inst_1 _inst_3) M N _inst_1 _inst_3 (MulHom.mulHomClass.{u2, u1} M N _inst_1 _inst_3)) g) s) -> (Eq.{max (succ u2) (succ u1)} (MulHom.{u2, u1} M N _inst_1 _inst_3) f g))
 Case conversion may be inaccurate. Consider using '#align mul_hom.eq_of_eq_on_mdense MulHom.eq_of_eqOn_denseₓ'. -/
 @[to_additive]
 theorem eq_of_eqOn_dense {s : Set M} (hs : closure s = ⊤) {f g : M →ₙ* N} (h : s.EqOn f g) :
@@ -730,7 +728,7 @@ add_decl_doc AddHom.ofDense
 lean 3 declaration is
   forall {M : Type.{u1}} {N : Type.{u2}} [_inst_1 : Semigroup.{u1} M] [_inst_2 : Semigroup.{u2} N] {s : Set.{u1} M} (f : M -> N) (hs : Eq.{succ u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.closure.{u1} M (Semigroup.toHasMul.{u1} M _inst_1) s) (Top.top.{u1} (Subsemigroup.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) (Subsemigroup.hasTop.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.Mem.{u1, u1} M (Set.{u1} M) (Set.hasMem.{u1} M) y s) -> (Eq.{succ u2} N (f (HMul.hMul.{u1, u1, u1} M M M (instHMul.{u1} M (Semigroup.toHasMul.{u1} M _inst_1)) x y)) (HMul.hMul.{u2, u2, u2} N N N (instHMul.{u2} N (Semigroup.toHasMul.{u2} N _inst_2)) (f x) (f y)))), Eq.{max (succ u1) (succ u2)} ((fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) (coeFn.{max (succ u2) (succ u1), max (succ u1) (succ u2)} (MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (fun (_x : MulHom.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) => M -> N) (MulHom.hasCoeToFun.{u1, u2} M N (Semigroup.toHasMul.{u1} M _inst_1) (Semigroup.toHasMul.{u2} N _inst_2)) (MulHom.ofDense.{u1, u2} M N _inst_1 _inst_2 s f hs hmul)) f
 but is expected to have type
-  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Semigroup.{u2} M] [_inst_2 : Semigroup.{u1} N] {s : Set.{u2} M} (f : M -> N) (hs : Eq.{succ u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.closure.{u2} M (Semigroup.toMul.{u2} M _inst_1) s) (Top.top.{u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.mem.{u2, u2} M (Set.{u2} M) (Set.instMembershipSet.{u2} M) y s) -> (Eq.{succ u1} N (f (HMul.hMul.{u2, u2, u2} M M M (instHMul.{u2} M (Semigroup.toMul.{u2} M _inst_1)) x y)) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N _inst_2)) (f x) (f y)))), Eq.{max (succ u2) (succ u1)} (forall (a : M), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2398 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2) (MulHom.mulHomClass.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2))) (MulHom.ofDense.{u2, u1} M N _inst_1 _inst_2 s f hs hmul)) f
+  forall {M : Type.{u2}} {N : Type.{u1}} [_inst_1 : Semigroup.{u2} M] [_inst_2 : Semigroup.{u1} N] {s : Set.{u2} M} (f : M -> N) (hs : Eq.{succ u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.closure.{u2} M (Semigroup.toMul.{u2} M _inst_1) s) (Top.top.{u2} (Subsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)) (Subsemigroup.instTopSubsemigroup.{u2} M (Semigroup.toMul.{u2} M _inst_1)))) (hmul : forall (x : M) (y : M), (Membership.mem.{u2, u2} M (Set.{u2} M) (Set.instMembershipSet.{u2} M) y s) -> (Eq.{succ u1} N (f (HMul.hMul.{u2, u2, u2} M M M (instHMul.{u2} M (Semigroup.toMul.{u2} M _inst_1)) x y)) (HMul.hMul.{u1, u1, u1} N N N (instHMul.{u1} N (Semigroup.toMul.{u1} N _inst_2)) (f x) (f y)))), Eq.{max (succ u2) (succ u1)} (forall (a : M), (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) a) (FunLike.coe.{max (succ u2) (succ u1), succ u2, succ u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M (fun (_x : M) => (fun (x._@.Mathlib.Algebra.Hom.Group._hyg.2372 : M) => N) _x) (MulHomClass.toFunLike.{max u2 u1, u2, u1} (MulHom.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2)) M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2) (MulHom.mulHomClass.{u2, u1} M N (Semigroup.toMul.{u2} M _inst_1) (Semigroup.toMul.{u1} N _inst_2))) (MulHom.ofDense.{u2, u1} M N _inst_1 _inst_2 s f hs hmul)) f
 Case conversion may be inaccurate. Consider using '#align mul_hom.coe_of_mdense MulHom.coe_ofDenseₓ'. -/
 @[simp, norm_cast, to_additive]
 theorem coe_ofDense [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : closure s = ⊤)
Diff
@@ -262,16 +262,16 @@ theorem coe_bot : ((⊥ : Subsemigroup M) : Set M) = ∅ :=
 
 /-- The inf of two subsemigroups is their intersection. -/
 @[to_additive "The inf of two `add_subsemigroup`s is their intersection."]
-instance : HasInf (Subsemigroup M) :=
+instance : Inf (Subsemigroup M) :=
   ⟨fun S₁ S₂ =>
     { carrier := S₁ ∩ S₂
       mul_mem' := fun _ _ ⟨hx, hx'⟩ ⟨hy, hy'⟩ => ⟨S₁.mul_mem hx hy, S₂.mul_mem hx' hy'⟩ }⟩
 
 /- warning: subsemigroup.coe_inf -> Subsemigroup.coe_inf is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (p : Subsemigroup.{u1} M _inst_1) (p' : Subsemigroup.{u1} M _inst_1), Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (HasInf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) p p')) (Inter.inter.{u1} (Set.{u1} M) (Set.hasInter.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) p) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) p'))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (p : Subsemigroup.{u1} M _inst_1) (p' : Subsemigroup.{u1} M _inst_1), Eq.{succ u1} (Set.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) p p')) (Inter.inter.{u1} (Set.{u1} M) (Set.hasInter.{u1} M) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) p) ((fun (a : Type.{u1}) (b : Type.{u1}) [self : HasLiftT.{succ u1, succ u1} a b] => self.0) (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (HasLiftT.mk.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (CoeTCₓ.coe.{succ u1, succ u1} (Subsemigroup.{u1} M _inst_1) (Set.{u1} M) (SetLike.Set.hasCoeT.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)))) p'))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (p : Subsemigroup.{u1} M _inst_1) (p' : Subsemigroup.{u1} M _inst_1), Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (HasInf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instHasInfSubsemigroup.{u1} M _inst_1) p p')) (Inter.inter.{u1} (Set.{u1} M) (Set.instInterSet.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) p) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) p'))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (p : Subsemigroup.{u1} M _inst_1) (p' : Subsemigroup.{u1} M _inst_1), Eq.{succ u1} (Set.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSubsemigroup.{u1} M _inst_1) p p')) (Inter.inter.{u1} (Set.{u1} M) (Set.instInterSet.{u1} M) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) p) (SetLike.coe.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1) p'))
 Case conversion may be inaccurate. Consider using '#align subsemigroup.coe_inf Subsemigroup.coe_infₓ'. -/
 @[simp, to_additive]
 theorem coe_inf (p p' : Subsemigroup M) : ((p ⊓ p' : Subsemigroup M) : Set M) = p ∩ p' :=
@@ -281,9 +281,9 @@ theorem coe_inf (p p' : Subsemigroup M) : ((p ⊓ p' : Subsemigroup M) : Set M)
 
 /- warning: subsemigroup.mem_inf -> Subsemigroup.mem_inf is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {p : Subsemigroup.{u1} M _inst_1} {p' : Subsemigroup.{u1} M _inst_1} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (HasInf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) p p')) (And (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p) (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p'))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {p : Subsemigroup.{u1} M _inst_1} {p' : Subsemigroup.{u1} M _inst_1} {x : M}, Iff (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.hasInf.{u1} M _inst_1) p p')) (And (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p) (Membership.Mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.hasMem.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.setLike.{u1} M _inst_1)) x p'))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {p : Subsemigroup.{u1} M _inst_1} {p' : Subsemigroup.{u1} M _inst_1} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (HasInf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instHasInfSubsemigroup.{u1} M _inst_1) p p')) (And (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p) (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p'))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] {p : Subsemigroup.{u1} M _inst_1} {p' : Subsemigroup.{u1} M _inst_1} {x : M}, Iff (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x (Inf.inf.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instInfSubsemigroup.{u1} M _inst_1) p p')) (And (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p) (Membership.mem.{u1, u1} M (Subsemigroup.{u1} M _inst_1) (SetLike.instMembership.{u1, u1} (Subsemigroup.{u1} M _inst_1) M (Subsemigroup.instSetLikeSubsemigroup.{u1} M _inst_1)) x p'))
 Case conversion may be inaccurate. Consider using '#align subsemigroup.mem_inf Subsemigroup.mem_infₓ'. -/
 @[simp, to_additive]
 theorem mem_inf {p p' : Subsemigroup M} {x : M} : x ∈ p ⊓ p' ↔ x ∈ p ∧ x ∈ p' :=
@@ -571,9 +571,9 @@ theorem closure_univ : closure (univ : Set M) = ⊤ :=
 
 /- warning: subsemigroup.closure_union -> Subsemigroup.closure_union is a dubious translation:
 lean 3 declaration is
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (s : Set.{u1} M) (t : Set.{u1} M), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Union.union.{u1} (Set.{u1} M) (Set.hasUnion.{u1} M) s t)) (HasSup.sup.{u1} (Subsemigroup.{u1} M _inst_1) (SemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (Lattice.toSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toLattice.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (s : Set.{u1} M) (t : Set.{u1} M), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Union.union.{u1} (Set.{u1} M) (Set.hasUnion.{u1} M) s t)) (Sup.sup.{u1} (Subsemigroup.{u1} M _inst_1) (SemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (Lattice.toSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toLattice.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.completeLattice.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
 but is expected to have type
-  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (s : Set.{u1} M) (t : Set.{u1} M), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Union.union.{u1} (Set.{u1} M) (Set.instUnionSet.{u1} M) s t)) (HasSup.sup.{u1} (Subsemigroup.{u1} M _inst_1) (SemilatticeSup.toHasSup.{u1} (Subsemigroup.{u1} M _inst_1) (Lattice.toSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toLattice.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
+  forall {M : Type.{u1}} [_inst_1 : Mul.{u1} M] (s : Set.{u1} M) (t : Set.{u1} M), Eq.{succ u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.closure.{u1} M _inst_1 (Union.union.{u1} (Set.{u1} M) (Set.instUnionSet.{u1} M) s t)) (Sup.sup.{u1} (Subsemigroup.{u1} M _inst_1) (SemilatticeSup.toSup.{u1} (Subsemigroup.{u1} M _inst_1) (Lattice.toSemilatticeSup.{u1} (Subsemigroup.{u1} M _inst_1) (CompleteLattice.toLattice.{u1} (Subsemigroup.{u1} M _inst_1) (Subsemigroup.instCompleteLatticeSubsemigroup.{u1} M _inst_1)))) (Subsemigroup.closure.{u1} M _inst_1 s) (Subsemigroup.closure.{u1} M _inst_1 t))
 Case conversion may be inaccurate. Consider using '#align subsemigroup.closure_union Subsemigroup.closure_unionₓ'. -/
 @[to_additive]
 theorem closure_union (s t : Set M) : closure (s ∪ t) = closure s ⊔ closure t :=

Changes in mathlib4

mathlib3
mathlib4
chore(GroupTheory): rename induction arguments for Sub{semigroup,monoid,group} (#11461)

The additive version are still incorrectly named, but these can easily be tracked down later (#11462) by searching for to_additive (attr := elab_as_elim).

Diff
@@ -353,22 +353,22 @@ is preserved under multiplication, then `p` holds for all elements of the closur
 @[to_additive (attr := elab_as_elim) "An induction principle for additive closure membership. If `p`
   holds for all elements of `s`, and is preserved under addition, then `p` holds for all
   elements of the additive closure of `s`."]
-theorem closure_induction {p : M → Prop} {x} (h : x ∈ closure s) (Hs : ∀ x ∈ s, p x)
-    (Hmul : ∀ x y, p x → p y → p (x * y)) : p x :=
-  (@closure_le _ _ _ ⟨p, Hmul _ _⟩).2 Hs h
+theorem closure_induction {p : M → Prop} {x} (h : x ∈ closure s) (mem : ∀ x ∈ s, p x)
+    (mul : ∀ x y, p x → p y → p (x * y)) : p x :=
+  (@closure_le _ _ _ ⟨p, mul _ _⟩).2 mem h
 #align subsemigroup.closure_induction Subsemigroup.closure_induction
 #align add_subsemigroup.closure_induction AddSubsemigroup.closure_induction
 
 /-- A dependent version of `Subsemigroup.closure_induction`.  -/
 @[to_additive (attr := elab_as_elim) "A dependent version of `AddSubsemigroup.closure_induction`. "]
 theorem closure_induction' (s : Set M) {p : ∀ x, x ∈ closure s → Prop}
-    (Hs : ∀ (x) (h : x ∈ s), p x (subset_closure h))
-    (Hmul : ∀ x hx y hy, p x hx → p y hy → p (x * y) (mul_mem hx hy)) {x} (hx : x ∈ closure s) :
+    (mem : ∀ (x) (h : x ∈ s), p x (subset_closure h))
+    (mul : ∀ x hx y hy, p x hx → p y hy → p (x * y) (mul_mem hx hy)) {x} (hx : x ∈ closure s) :
     p x hx := by
   refine' Exists.elim _ fun (hx : x ∈ closure s) (hc : p x hx) => hc
   exact
-    closure_induction hx (fun x hx => ⟨_, Hs x hx⟩) fun x y ⟨hx', hx⟩ ⟨hy', hy⟩ =>
-      ⟨_, Hmul _ _ _ _ hx hy⟩
+    closure_induction hx (fun x hx => ⟨_, mem x hx⟩) fun x y ⟨hx', hx⟩ ⟨hy', hy⟩ =>
+      ⟨_, mul _ _ _ _ hx hy⟩
 #align subsemigroup.closure_induction' Subsemigroup.closure_induction'
 #align add_subsemigroup.closure_induction' AddSubsemigroup.closure_induction'
 
@@ -391,9 +391,10 @@ and verify that `p x` and `p y` imply `p (x * y)`. -/
   `AddSubsemigroup.closure s = ⊤`, then in order to prove that some predicate `p` holds
   for all `x : M` it suffices to verify `p x` for `x ∈ s`, and verify that `p x` and `p y` imply
   `p (x + y)`."]
-theorem dense_induction {p : M → Prop} (x : M) {s : Set M} (hs : closure s = ⊤) (Hs : ∀ x ∈ s, p x)
-    (Hmul : ∀ x y, p x → p y → p (x * y)) : p x := by
-  have : ∀ x ∈ closure s, p x := fun x hx => closure_induction hx Hs Hmul
+theorem dense_induction {p : M → Prop} (x : M) {s : Set M} (hs : closure s = ⊤)
+    (mem : ∀ x ∈ s, p x)
+    (mul : ∀ x y, p x → p y → p (x * y)) : p x := by
+  have : ∀ x ∈ closure s, p x := fun x hx => closure_induction hx mem mul
   simpa [hs] using this x
 #align subsemigroup.dense_induction Subsemigroup.dense_induction
 #align add_subsemigroup.dense_induction AddSubsemigroup.dense_induction
chore(*): remove empty lines between variable statements (#11418)

Empty lines were removed by executing the following Python script twice

import os
import re


# Loop through each file in the repository
for dir_path, dirs, files in os.walk('.'):
  for filename in files:
    if filename.endswith('.lean'):
      file_path = os.path.join(dir_path, filename)

      # Open the file and read its contents
      with open(file_path, 'r') as file:
        content = file.read()

      # Use a regular expression to replace sequences of "variable" lines separated by empty lines
      # with sequences without empty lines
      modified_content = re.sub(r'(variable.*\n)\n(variable(?! .* in))', r'\1\2', content)

      # Write the modified content back to the file
      with open(file_path, 'w') as file:
        file.write(modified_content)
Diff
@@ -55,7 +55,6 @@ variable {M : Type*} {N : Type*} {A : Type*}
 section NonAssoc
 
 variable [Mul M] {s : Set M}
-
 variable [Add A] {t : Set A}
 
 /-- `MulMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(*)` -/
chore: Remove ball and bex from lemma names (#10816)

ball for "bounded forall" and bex for "bounded exists" are from experience very confusing abbreviations. This PR renames them to forall_mem and exists_mem in the few Set lemma names that mention them.

Also deprecate ball_image_of_ball, mem_image_elim, mem_image_elim_on since those lemmas are duplicates of the renamed lemmas (apart from argument order and implicitness, which I am also fixing by making the binder in the RHS of forall_mem_image semi-implicit), have obscure names and are completely unused.

Diff
@@ -252,7 +252,7 @@ theorem mem_sInf {S : Set (Subsemigroup M)} {x : M} : x ∈ sInf S ↔ ∀ p ∈
 
 @[to_additive]
 theorem mem_iInf {ι : Sort*} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
-  simp only [iInf, mem_sInf, Set.forall_range_iff]
+  simp only [iInf, mem_sInf, Set.forall_mem_range]
 #align subsemigroup.mem_infi Subsemigroup.mem_iInf
 #align add_subsemigroup.mem_infi AddSubsemigroup.mem_iInf
 
chore: move Mathlib to v4.7.0-rc1 (#11162)

This is a very large PR, but it has been reviewed piecemeal already in PRs to the bump/v4.7.0 branch as we update to intermediate nightlies.

Co-authored-by: Scott Morrison <scott.morrison@gmail.com> Co-authored-by: Kyle Miller <kmill31415@gmail.com> Co-authored-by: damiano <adomani@gmail.com>

Diff
@@ -279,7 +279,7 @@ instance : CompleteLattice (Subsemigroup M) :=
     inf_le_left := fun _ _ _ => And.left
     inf_le_right := fun _ _ _ => And.right }
 
-@[to_additive (attr := simp)]
+@[to_additive]
 theorem subsingleton_of_subsingleton [Subsingleton (Subsemigroup M)] : Subsingleton M := by
   constructor; intro x y
   have : ∀ a : M, a ∈ (⊥ : Subsemigroup M) := by simp [Subsingleton.elim (⊥ : Subsemigroup M) ⊤]
chore: bump aesop; update syntax (#10955)

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -76,7 +76,7 @@ export AddMemClass (add_mem)
 
 attribute [to_additive] MulMemClass
 
-attribute [aesop safe apply (rule_sets [SetLike])] mul_mem add_mem
+attribute [aesop safe apply (rule_sets := [SetLike])] mul_mem add_mem
 
 /-- A subsemigroup of a magma `M` is a subset closed under multiplication. -/
 structure Subsemigroup (M : Type*) [Mul M] where
@@ -308,7 +308,7 @@ theorem mem_closure {x : M} : x ∈ closure s ↔ ∀ S : Subsemigroup M, s ⊆
 #align add_subsemigroup.mem_closure AddSubsemigroup.mem_closure
 
 /-- The subsemigroup generated by a set includes the set. -/
-@[to_additive (attr := simp, aesop safe 20 apply (rule_sets [SetLike]))
+@[to_additive (attr := simp, aesop safe 20 apply (rule_sets := [SetLike]))
   "The `AddSubsemigroup` generated by a set includes the set."]
 theorem subset_closure : s ⊆ closure s := fun _ hx => mem_closure.2 fun _ hS => hS hx
 #align subsemigroup.subset_closure Subsemigroup.subset_closure
refactor(Algebra/Hom): transpose Hom and file name (#8095)

I believe the file defining a type of morphisms belongs alongside the file defining the structure this morphism works on. So I would like to reorganize the files in the Mathlib.Algebra.Hom folder so that e.g. Mathlib.Algebra.Hom.Ring becomes Mathlib.Algebra.Ring.Hom and Mathlib.Algebra.Hom.NonUnitalAlg becomes Mathlib.Algebra.Algebra.NonUnitalHom.

While fixing the imports I went ahead and sorted them for good luck.

The full list of changes is: renamed: Mathlib/Algebra/Hom/NonUnitalAlg.lean -> Mathlib/Algebra/Algebra/NonUnitalHom.lean renamed: Mathlib/Algebra/Hom/Aut.lean -> Mathlib/Algebra/Group/Aut.lean renamed: Mathlib/Algebra/Hom/Commute.lean -> Mathlib/Algebra/Group/Commute/Hom.lean renamed: Mathlib/Algebra/Hom/Embedding.lean -> Mathlib/Algebra/Group/Embedding.lean renamed: Mathlib/Algebra/Hom/Equiv/Basic.lean -> Mathlib/Algebra/Group/Equiv/Basic.lean renamed: Mathlib/Algebra/Hom/Equiv/TypeTags.lean -> Mathlib/Algebra/Group/Equiv/TypeTags.lean renamed: Mathlib/Algebra/Hom/Equiv/Units/Basic.lean -> Mathlib/Algebra/Group/Units/Equiv.lean renamed: Mathlib/Algebra/Hom/Equiv/Units/GroupWithZero.lean -> Mathlib/Algebra/GroupWithZero/Units/Equiv.lean renamed: Mathlib/Algebra/Hom/Freiman.lean -> Mathlib/Algebra/Group/Freiman.lean renamed: Mathlib/Algebra/Hom/Group/Basic.lean -> Mathlib/Algebra/Group/Hom/Basic.lean renamed: Mathlib/Algebra/Hom/Group/Defs.lean -> Mathlib/Algebra/Group/Hom/Defs.lean renamed: Mathlib/Algebra/Hom/GroupAction.lean -> Mathlib/GroupTheory/GroupAction/Hom.lean renamed: Mathlib/Algebra/Hom/GroupInstances.lean -> Mathlib/Algebra/Group/Hom/Instances.lean renamed: Mathlib/Algebra/Hom/Iterate.lean -> Mathlib/Algebra/GroupPower/IterateHom.lean renamed: Mathlib/Algebra/Hom/Centroid.lean -> Mathlib/Algebra/Ring/CentroidHom.lean renamed: Mathlib/Algebra/Hom/Ring/Basic.lean -> Mathlib/Algebra/Ring/Hom/Basic.lean renamed: Mathlib/Algebra/Hom/Ring/Defs.lean -> Mathlib/Algebra/Ring/Hom/Defs.lean renamed: Mathlib/Algebra/Hom/Units.lean -> Mathlib/Algebra/Group/Units/Hom.lean

Zulip thread: https://leanprover.zulipchat.com/#narrow/stream/287929-mathlib4/topic/Reorganizing.20.60Mathlib.2EAlgebra.2EHom.60

Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzzard,
 Amelia Livingston, Yury Kudryashov, Yakov Pechersky
 -/
-import Mathlib.Algebra.Hom.Group.Defs
+import Mathlib.Algebra.Group.Hom.Defs
 import Mathlib.Data.Set.Lattice
 import Mathlib.Data.SetLike.Basic
 
feat: add a SetLike default rule set for aesop (#7111)

This creates a new aesop rule set called SetLike to house lemmas about membership in subobjects.

Lemmas like pow_mem should be included in the rule set:

@[to_additive (attr := aesop safe apply (rule_sets [SetLike]))]
theorem pow_mem {M A} [Monoid M] [SetLike A M] [SubmonoidClass A M] {S : A} {x : M}
(hx : x ∈ S) : ∀ n : ℕ, x ^ n ∈ S

Lemmas about closures, like AddSubmonoid.closure should be included in the rule set, but they should be assigned a penalty (here we choose 20 throughout) so that they are not attempted before the general purpose ones like pow_mem.

@[to_additive (attr := simp, aesop safe 20 apply (rule_sets [SetLike]))
  "The `AddSubmonoid` generated by a set includes the set."]
theorem subset_closure : s ⊆ closure s := fun _ hx => mem_closure.2 fun _ hS => hS hx

In order for aesop to make effective use of AddSubmonoid.closure it needs the following new lemma.

@[aesop 5% apply (rule_sets [SetLike])]
lemma mem_of_subset {s : Set B} (hp : s ⊆ p) {x : B} (hx : x ∈ s) : x ∈ p := hp hx

Note: this lemma is marked as very unsafe (5%) because it will apply whenever the goal is of the form x ∈ p where p is any term of a SetLike instance; and moreover, it will create s as a metavariable, which is in general a terrible idea, but necessary for the reason mentioned above.

Diff
@@ -76,6 +76,8 @@ export AddMemClass (add_mem)
 
 attribute [to_additive] MulMemClass
 
+attribute [aesop safe apply (rule_sets [SetLike])] mul_mem add_mem
+
 /-- A subsemigroup of a magma `M` is a subset closed under multiplication. -/
 structure Subsemigroup (M : Type*) [Mul M] where
   /-- The carrier of a subsemigroup. -/
@@ -306,7 +308,8 @@ theorem mem_closure {x : M} : x ∈ closure s ↔ ∀ S : Subsemigroup M, s ⊆
 #align add_subsemigroup.mem_closure AddSubsemigroup.mem_closure
 
 /-- The subsemigroup generated by a set includes the set. -/
-@[to_additive (attr := simp) "The `AddSubsemigroup` generated by a set includes the set."]
+@[to_additive (attr := simp, aesop safe 20 apply (rule_sets [SetLike]))
+  "The `AddSubsemigroup` generated by a set includes the set."]
 theorem subset_closure : s ⊆ closure s := fun _ hx => mem_closure.2 fun _ hS => hS hx
 #align subsemigroup.subset_closure Subsemigroup.subset_closure
 #align add_subsemigroup.subset_closure AddSubsemigroup.subset_closure
refactor: split Algebra.Hom.Group and Algebra.Hom.Ring (#7094)

Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzzard,
 Amelia Livingston, Yury Kudryashov, Yakov Pechersky
 -/
-import Mathlib.Algebra.Hom.Group
+import Mathlib.Algebra.Hom.Group.Defs
 import Mathlib.Data.Set.Lattice
 import Mathlib.Data.SetLike.Basic
 
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
@@ -50,7 +50,7 @@ subsemigroup, subsemigroups
 
 
 -- Only needed for notation
-variable {M : Type _} {N : Type _} {A : Type _}
+variable {M : Type*} {N : Type*} {A : Type*}
 
 section NonAssoc
 
@@ -59,7 +59,7 @@ variable [Mul M] {s : Set M}
 variable [Add A] {t : Set A}
 
 /-- `MulMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(*)` -/
-class MulMemClass (S : Type _) (M : Type _) [Mul M] [SetLike S M] : Prop where
+class MulMemClass (S : Type*) (M : Type*) [Mul M] [SetLike S M] : Prop where
   /-- A substructure satisfying `MulMemClass` is closed under multiplication. -/
   mul_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a * b ∈ s
 #align mul_mem_class MulMemClass
@@ -67,7 +67,7 @@ class MulMemClass (S : Type _) (M : Type _) [Mul M] [SetLike S M] : Prop where
 export MulMemClass (mul_mem)
 
 /-- `AddMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(+)` -/
-class AddMemClass (S : Type _) (M : Type _) [Add M] [SetLike S M] : Prop where
+class AddMemClass (S : Type*) (M : Type*) [Add M] [SetLike S M] : Prop where
   /-- A substructure satisfying `AddMemClass` is closed under addition. -/
   add_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a + b ∈ s
 #align add_mem_class AddMemClass
@@ -77,7 +77,7 @@ export AddMemClass (add_mem)
 attribute [to_additive] MulMemClass
 
 /-- A subsemigroup of a magma `M` is a subset closed under multiplication. -/
-structure Subsemigroup (M : Type _) [Mul M] where
+structure Subsemigroup (M : Type*) [Mul M] where
   /-- The carrier of a subsemigroup. -/
   carrier : Set M
   /-- The product of two elements of a subsemigroup belongs to the subsemigroup. -/
@@ -85,7 +85,7 @@ structure Subsemigroup (M : Type _) [Mul M] where
 #align subsemigroup Subsemigroup
 
 /-- An additive subsemigroup of an additive magma `M` is a subset closed under addition. -/
-structure AddSubsemigroup (M : Type _) [Add M] where
+structure AddSubsemigroup (M : Type*) [Add M] where
   /-- The carrier of an additive subsemigroup. -/
   carrier : Set M
   /-- The sum of two elements of an additive subsemigroup belongs to the subsemigroup. -/
@@ -249,13 +249,13 @@ theorem mem_sInf {S : Set (Subsemigroup M)} {x : M} : x ∈ sInf S ↔ ∀ p ∈
 #align add_subsemigroup.mem_Inf AddSubsemigroup.mem_sInf
 
 @[to_additive]
-theorem mem_iInf {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
+theorem mem_iInf {ι : Sort*} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
   simp only [iInf, mem_sInf, Set.forall_range_iff]
 #align subsemigroup.mem_infi Subsemigroup.mem_iInf
 #align add_subsemigroup.mem_infi AddSubsemigroup.mem_iInf
 
 @[to_additive (attr := simp, norm_cast)]
-theorem coe_iInf {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
+theorem coe_iInf {ι : Sort*} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
   simp only [iInf, coe_sInf, Set.biInter_range]
 #align subsemigroup.coe_infi Subsemigroup.coe_iInf
 #align add_subsemigroup.coe_infi AddSubsemigroup.coe_iInf
@@ -445,7 +445,7 @@ theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m}
 #align add_subsemigroup.closure_singleton_le_iff_mem AddSubsemigroup.closure_singleton_le_iff_mem
 
 @[to_additive]
-theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
+theorem mem_iSup {ι : Sort*} (p : ι → Subsemigroup M) {m : M} :
     (m ∈ ⨆ i, p i) ↔ ∀ N, (∀ i, p i ≤ N) → m ∈ N := by
   rw [← closure_singleton_le_iff_mem, le_iSup_iff]
   simp only [closure_singleton_le_iff_mem]
@@ -453,7 +453,7 @@ theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
 #align add_subsemigroup.mem_supr AddSubsemigroup.mem_iSup
 
 @[to_additive]
-theorem iSup_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
+theorem iSup_eq_closure {ι : Sort*} (p : ι → Subsemigroup M) :
     ⨆ i, p i = Subsemigroup.closure (⋃ i, (p i : Set M)) := by
   simp_rw [Subsemigroup.closure_iUnion, Subsemigroup.closure_eq]
 #align subsemigroup.supr_eq_closure Subsemigroup.iSup_eq_closure
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
@@ -3,16 +3,13 @@ Copyright (c) 2018 Johannes Hölzl. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzzard,
 Amelia Livingston, Yury Kudryashov, Yakov Pechersky
-
-! This file was ported from Lean 3 source module group_theory.subsemigroup.basic
-! leanprover-community/mathlib commit feb99064803fd3108e37c18b0f77d0a8344677a3
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.Algebra.Hom.Group
 import Mathlib.Data.Set.Lattice
 import Mathlib.Data.SetLike.Basic
 
+#align_import group_theory.subsemigroup.basic from "leanprover-community/mathlib"@"feb99064803fd3108e37c18b0f77d0a8344677a3"
+
 /-!
 # Subsemigroups: definition and `CompleteLattice` structure
 
fix: precedences of ⨆⋃⋂⨅ (#5614)
Diff
@@ -457,7 +457,7 @@ theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
 
 @[to_additive]
 theorem iSup_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
-    (⨆ i, p i) = Subsemigroup.closure (⋃ i, (p i : Set M)) := by
+    ⨆ i, p i = Subsemigroup.closure (⋃ i, (p i : Set M)) := by
   simp_rw [Subsemigroup.closure_iUnion, Subsemigroup.closure_eq]
 #align subsemigroup.supr_eq_closure Subsemigroup.iSup_eq_closure
 #align add_subsemigroup.supr_eq_closure AddSubsemigroup.iSup_eq_closure
chore: fix upper/lowercase in comments (#4360)
  • Run a non-interactive version of fix-comments.py on all files.
  • Go through the diff and manually add/discard/edit chunks.
Diff
@@ -14,7 +14,7 @@ import Mathlib.Data.Set.Lattice
 import Mathlib.Data.SetLike.Basic
 
 /-!
-# Subsemigroups: definition and `complete_lattice` structure
+# Subsemigroups: definition and `CompleteLattice` structure
 
 This file defines bundled multiplicative and additive subsemigroups. We also define
 a `CompleteLattice` structure on `Subsemigroup`s,
chore: Rename to sSup/iSup (#3938)

As discussed on Zulip

Renames

  • supₛsSup
  • infₛsInf
  • supᵢiSup
  • infᵢiInf
  • bsupₛbsSup
  • binfₛbsInf
  • bsupᵢbiSup
  • binfᵢbiInf
  • csupₛcsSup
  • cinfₛcsInf
  • csupᵢciSup
  • cinfᵢciInf
  • unionₛsUnion
  • interₛsInter
  • unionᵢiUnion
  • interᵢiInter
  • bunionₛbsUnion
  • binterₛbsInter
  • bunionᵢbiUnion
  • binterᵢbiInter

Co-authored-by: Parcly Taxel <reddeloostw@gmail.com>

Diff
@@ -236,38 +236,38 @@ instance : InfSet (Subsemigroup M) :=
   ⟨fun s =>
     { carrier := ⋂ t ∈ s, ↑t
       mul_mem' := fun hx hy =>
-        Set.mem_binterᵢ fun i h =>
-          i.mul_mem (by apply Set.mem_interᵢ₂.1 hx i h) (by apply Set.mem_interᵢ₂.1 hy i h) }⟩
+        Set.mem_biInter fun i h =>
+          i.mul_mem (by apply Set.mem_iInter₂.1 hx i h) (by apply Set.mem_iInter₂.1 hy i h) }⟩
 
 @[to_additive (attr := simp, norm_cast)]
-theorem coe_infₛ (S : Set (Subsemigroup M)) : ((infₛ S : Subsemigroup M) : Set M) = ⋂ s ∈ S, ↑s :=
+theorem coe_sInf (S : Set (Subsemigroup M)) : ((sInf S : Subsemigroup M) : Set M) = ⋂ s ∈ S, ↑s :=
   rfl
-#align subsemigroup.coe_Inf Subsemigroup.coe_infₛ
-#align add_subsemigroup.coe_Inf AddSubsemigroup.coe_infₛ
+#align subsemigroup.coe_Inf Subsemigroup.coe_sInf
+#align add_subsemigroup.coe_Inf AddSubsemigroup.coe_sInf
 
 @[to_additive]
-theorem mem_infₛ {S : Set (Subsemigroup M)} {x : M} : x ∈ infₛ S ↔ ∀ p ∈ S, x ∈ p :=
-  Set.mem_interᵢ₂
-#align subsemigroup.mem_Inf Subsemigroup.mem_infₛ
-#align add_subsemigroup.mem_Inf AddSubsemigroup.mem_infₛ
+theorem mem_sInf {S : Set (Subsemigroup M)} {x : M} : x ∈ sInf S ↔ ∀ p ∈ S, x ∈ p :=
+  Set.mem_iInter₂
+#align subsemigroup.mem_Inf Subsemigroup.mem_sInf
+#align add_subsemigroup.mem_Inf AddSubsemigroup.mem_sInf
 
 @[to_additive]
-theorem mem_infᵢ {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
-  simp only [infᵢ, mem_infₛ, Set.forall_range_iff]
-#align subsemigroup.mem_infi Subsemigroup.mem_infᵢ
-#align add_subsemigroup.mem_infi AddSubsemigroup.mem_infᵢ
+theorem mem_iInf {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ ⨅ i, S i) ↔ ∀ i, x ∈ S i := by
+  simp only [iInf, mem_sInf, Set.forall_range_iff]
+#align subsemigroup.mem_infi Subsemigroup.mem_iInf
+#align add_subsemigroup.mem_infi AddSubsemigroup.mem_iInf
 
 @[to_additive (attr := simp, norm_cast)]
-theorem coe_infᵢ {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
-  simp only [infᵢ, coe_infₛ, Set.binterᵢ_range]
-#align subsemigroup.coe_infi Subsemigroup.coe_infᵢ
-#align add_subsemigroup.coe_infi AddSubsemigroup.coe_infᵢ
+theorem coe_iInf {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
+  simp only [iInf, coe_sInf, Set.biInter_range]
+#align subsemigroup.coe_infi Subsemigroup.coe_iInf
+#align add_subsemigroup.coe_infi AddSubsemigroup.coe_iInf
 
 /-- subsemigroups of a monoid form a complete lattice. -/
 @[to_additive "The `AddSubsemigroup`s of an `AddMonoid` form a complete lattice."]
 instance : CompleteLattice (Subsemigroup M) :=
   { completeLatticeOfInf (Subsemigroup M) fun _ =>
-      IsGLB.of_image SetLike.coe_subset_coe isGLB_binfᵢ with
+      IsGLB.of_image SetLike.coe_subset_coe isGLB_biInf with
     le := (· ≤ ·)
     lt := (· < ·)
     bot := ⊥
@@ -275,7 +275,7 @@ instance : CompleteLattice (Subsemigroup M) :=
     top := ⊤
     le_top := fun _ x _ => mem_top x
     inf := (· ⊓ ·)
-    infₛ := InfSet.infₛ
+    sInf := InfSet.sInf
     le_inf := fun _ _ _ ha hb _ hx => ⟨ha hx, hb hx⟩
     inf_le_left := fun _ _ _ => And.left
     inf_le_right := fun _ _ _ => And.right }
@@ -298,13 +298,13 @@ instance [hn : Nonempty M] : Nontrivial (Subsemigroup M) :=
 /-- The `Subsemigroup` generated by a set. -/
 @[to_additive "The `AddSubsemigroup` generated by a set"]
 def closure (s : Set M) : Subsemigroup M :=
-  infₛ { S | s ⊆ S }
+  sInf { S | s ⊆ S }
 #align subsemigroup.closure Subsemigroup.closure
 #align add_subsemigroup.closure AddSubsemigroup.closure
 
 @[to_additive]
 theorem mem_closure {x : M} : x ∈ closure s ↔ ∀ S : Subsemigroup M, s ⊆ S → x ∈ S :=
-  mem_infₛ
+  mem_sInf
 #align subsemigroup.mem_closure Subsemigroup.mem_closure
 #align add_subsemigroup.mem_closure AddSubsemigroup.mem_closure
 
@@ -328,7 +328,7 @@ open Set
 @[to_additive (attr := simp)
   "An additive subsemigroup `S` includes `closure s` if and only if it includes `s`"]
 theorem closure_le : closure s ≤ S ↔ s ⊆ S :=
-  ⟨Subset.trans subset_closure, fun h => infₛ_le h⟩
+  ⟨Subset.trans subset_closure, fun h => sInf_le h⟩
 #align subsemigroup.closure_le Subsemigroup.closure_le
 #align add_subsemigroup.closure_le AddSubsemigroup.closure_le
 
@@ -436,10 +436,10 @@ theorem closure_union (s t : Set M) : closure (s ∪ t) = closure s ⊔ closure
 #align add_subsemigroup.closure_union AddSubsemigroup.closure_union
 
 @[to_additive]
-theorem closure_unionᵢ {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, closure (s i) :=
-  (Subsemigroup.gi M).gc.l_supᵢ
-#align subsemigroup.closure_Union Subsemigroup.closure_unionᵢ
-#align add_subsemigroup.closure_Union AddSubsemigroup.closure_unionᵢ
+theorem closure_iUnion {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, closure (s i) :=
+  (Subsemigroup.gi M).gc.l_iSup
+#align subsemigroup.closure_Union Subsemigroup.closure_iUnion
+#align add_subsemigroup.closure_Union AddSubsemigroup.closure_iUnion
 
 @[to_additive]
 theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m} ≤ p ↔ m ∈ p := by
@@ -448,19 +448,19 @@ theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m}
 #align add_subsemigroup.closure_singleton_le_iff_mem AddSubsemigroup.closure_singleton_le_iff_mem
 
 @[to_additive]
-theorem mem_supᵢ {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
+theorem mem_iSup {ι : Sort _} (p : ι → Subsemigroup M) {m : M} :
     (m ∈ ⨆ i, p i) ↔ ∀ N, (∀ i, p i ≤ N) → m ∈ N := by
-  rw [← closure_singleton_le_iff_mem, le_supᵢ_iff]
+  rw [← closure_singleton_le_iff_mem, le_iSup_iff]
   simp only [closure_singleton_le_iff_mem]
-#align subsemigroup.mem_supr Subsemigroup.mem_supᵢ
-#align add_subsemigroup.mem_supr AddSubsemigroup.mem_supᵢ
+#align subsemigroup.mem_supr Subsemigroup.mem_iSup
+#align add_subsemigroup.mem_supr AddSubsemigroup.mem_iSup
 
 @[to_additive]
-theorem supᵢ_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
+theorem iSup_eq_closure {ι : Sort _} (p : ι → Subsemigroup M) :
     (⨆ i, p i) = Subsemigroup.closure (⋃ i, (p i : Set M)) := by
-  simp_rw [Subsemigroup.closure_unionᵢ, Subsemigroup.closure_eq]
-#align subsemigroup.supr_eq_closure Subsemigroup.supᵢ_eq_closure
-#align add_subsemigroup.supr_eq_closure AddSubsemigroup.supᵢ_eq_closure
+  simp_rw [Subsemigroup.closure_iUnion, Subsemigroup.closure_eq]
+#align subsemigroup.supr_eq_closure Subsemigroup.iSup_eq_closure
+#align add_subsemigroup.supr_eq_closure AddSubsemigroup.iSup_eq_closure
 
 end Subsemigroup
 
feat: initialize_simps_projections automatically finds coercions (#2045)
  • initialize_simps_projections automatically find coercions if there is a Funlike or SetLike instance defined by one of the projections.
  • Some improvements compared to Lean 3:
    • Find coercions even if it is defined by a field of a parent structure
    • Find SetLike coercions

Not yet implemented (and rarely - if ever - used in mathlib3):

  • Automatic custom projections for algebraic notation (like +,*,...)

Co-authored-by: Johan Commelin <johan@commelin.net>

Diff
@@ -106,13 +106,6 @@ instance : SetLike (Subsemigroup M) M :=
 @[to_additive]
 instance : MulMemClass (Subsemigroup M) M where mul_mem := fun {_ _ _} => Subsemigroup.mul_mem' _
 
-/-- See Note [custom simps projection] -/
-@[to_additive "See Note [custom simps projection]"]
-def Simps.coe (S : Subsemigroup M) : Set M :=
-  S
-#align subsemigroup.simps.coe Subsemigroup.Simps.coe
-#align add_subsemigroup.simps.coe AddSubsemigroup.Simps.coe
-
 initialize_simps_projections Subsemigroup (carrier → coe)
 initialize_simps_projections AddSubsemigroup (carrier → coe)
 
refactor: rename HasSup/HasInf to Sup/Inf (#2475)

Co-authored-by: Yury G. Kudryashov <urkud@urkud.name>

Diff
@@ -221,7 +221,7 @@ theorem coe_bot : ((⊥ : Subsemigroup M) : Set M) = ∅ :=
 
 /-- The inf of two subsemigroups is their intersection. -/
 @[to_additive "The inf of two `AddSubsemigroup`s is their intersection."]
-instance : HasInf (Subsemigroup M) :=
+instance : Inf (Subsemigroup M) :=
   ⟨fun S₁ S₂ =>
     { carrier := S₁ ∩ S₂
       mul_mem' := fun ⟨hx, hx'⟩ ⟨hy, hy'⟩ => ⟨S₁.mul_mem hx hy, S₂.mul_mem hx' hy'⟩ }⟩
feat: to_additive raises linter errors; nested to_additive (#1819)
  • Turn info messages of to_additive into linter errors
  • Allow @[to_additive (attr := to_additive)] to additivize the generated lemma. This is useful for Pow -> SMul -> VAdd lemmas. We can write e.g. @[to_additive (attr := to_additive, simp)] to add the simp attribute to all 3 generated lemmas, and we can provide other options to each to_additive call separately (specifying a name / reorder).
  • The previous point was needed to cleanly get rid of some linter warnings. It also required some additional changes (addToAdditiveAttr now returns a value, turn a few (meta) definitions into mutual partial def, reorder some definitions, generalize additivizeLemmas to lists of more than 2 elements) that should have no visible effects for the user.
Diff
@@ -332,8 +332,8 @@ variable {S}
 open Set
 
 /-- A subsemigroup `S` includes `closure s` if and only if it includes `s`. -/
-@[simp,
-  to_additive "An additive subsemigroup `S` includes `closure s` if and only if it includes `s`"]
+@[to_additive (attr := simp)
+  "An additive subsemigroup `S` includes `closure s` if and only if it includes `s`"]
 theorem closure_le : closure s ≤ S ↔ s ⊆ S :=
   ⟨Subset.trans subset_closure, fun h => infₛ_le h⟩
 #align subsemigroup.closure_le Subsemigroup.closure_le
chore: resync ported files (#2135)

This PR resyncs the first 28 entries of https://leanprover-community.github.io/mathlib-port-status/out-of-sync.html after sorting by diff size.

  • resync Mathlib/Data/Bool/Count
  • resync Mathlib/Order/Max
  • resync Mathlib/Algebra/EuclideanDomain/Instances
  • resync Mathlib/Data/List/Duplicate
  • resync Mathlib/Data/Multiset/Nodup
  • resync Mathlib/Data/Set/Pointwise/ListOfFn
  • resync Mathlib/Dynamics/FixedPoints/Basic
  • resync Mathlib/Order/OmegaCompletePartialOrder
  • resync Mathlib/Order/PropInstances
  • resync Mathlib/Topology/LocallyFinite
  • resync Mathlib/Data/Bool/Set
  • resync Mathlib/Data/Fintype/Card
  • resync Mathlib/Data/Multiset/Bind
  • resync Mathlib/Data/Rat/Floor
  • resync Mathlib/Algebra/Order/Floor
  • resync Mathlib/Data/Int/Basic
  • resync Mathlib/Data/Int/Dvd/Basic
  • resync Mathlib/Data/List/Sort
  • resync Mathlib/Data/Nat/GCD/Basic
  • resync Mathlib/Data/Set/Enumerate
  • resync Mathlib/Data/Set/Intervals/OrdConnectedComponent
  • resync Mathlib/GroupTheory/Subsemigroup/Basic
  • resync Mathlib/Topology/Connected
  • resync Mathlib/Topology/NhdsSet
  • resync Mathlib/Algebra/BigOperators/Multiset/Lemmas
  • resync Mathlib/Algebra/CharZero/Infinite
  • resync Mathlib/Data/Multiset/Range
  • resync Mathlib/Data/Set/Pointwise/Finite
Diff
@@ -5,7 +5,7 @@ Authors: Johannes Hölzl, Kenny Lau, Johan Commelin, Mario Carneiro, Kevin Buzza
 Amelia Livingston, Yury Kudryashov, Yakov Pechersky
 
 ! This file was ported from Lean 3 source module group_theory.subsemigroup.basic
-! leanprover-community/mathlib commit 207cfac9fcd06138865b5d04f7091e46d9320432
+! leanprover-community/mathlib commit feb99064803fd3108e37c18b0f77d0a8344677a3
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
fix: Unbundled subclasses of outParam classes should not repeat the parents' outParam (#1832)

This PR fixes a large amount of issues encountered in the port of GroupTheory.Subgroup.Basic, #1797. Subobject classes such as MulMemClass and SubmonoidClass take a SetLike parameter, and we were used to just copy over the M : outParam Type declaration from SetLike. Since Lean 3 synthesized from left to right, we'd fill in the outParam from SetLike, then the Mul M instance would be available for synthesis and we'd be in business. In Lean 4 however, we often go from right to left, so that MulMemClass ?M S [?inst : Mul ?M] is handled first, which can't be solved before finding a Mul ?M instance on the metavariable ?M, causing search through all Mul instances.

The solution is: whenever a class is declared that takes another class as parameter (i.e. unbundled inheritance), the outParams of the parent class should be unmarked and become in-params in the child class. Then Lean will try to find the parent class instance first, fill in the outParams and we'll be able to synthesize the child class instance without problems.

Pair: leanprover-community/mathlib#18291

Diff
@@ -62,7 +62,7 @@ variable [Mul M] {s : Set M}
 variable [Add A] {t : Set A}
 
 /-- `MulMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(*)` -/
-class MulMemClass (S : Type _) (M : outParam <| Type _) [Mul M] [SetLike S M] : Prop where
+class MulMemClass (S : Type _) (M : Type _) [Mul M] [SetLike S M] : Prop where
   /-- A substructure satisfying `MulMemClass` is closed under multiplication. -/
   mul_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a * b ∈ s
 #align mul_mem_class MulMemClass
@@ -70,7 +70,7 @@ class MulMemClass (S : Type _) (M : outParam <| Type _) [Mul M] [SetLike S M] :
 export MulMemClass (mul_mem)
 
 /-- `AddMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(+)` -/
-class AddMemClass (S : Type _) (M : outParam <| Type _) [Add M] [SetLike S M] : Prop where
+class AddMemClass (S : Type _) (M : Type _) [Add M] [SetLike S M] : Prop where
   /-- A substructure satisfying `AddMemClass` is closed under addition. -/
   add_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a + b ∈ s
 #align add_mem_class AddMemClass
chore: fix most phantom #aligns (#1794)
Diff
@@ -177,7 +177,7 @@ variable (S)
 protected theorem mul_mem {x y : M} : x ∈ S → y ∈ S → x * y ∈ S :=
   Subsemigroup.mul_mem' S
 #align subsemigroup.mul_mem Subsemigroup.mul_mem
-#align add_subsemigroup.mul_mem AddSubsemigroup.add_mem
+#align add_subsemigroup.add_mem AddSubsemigroup.add_mem
 
 /-- The subsemigroup `M` of the magma `M`. -/
 @[to_additive "The additive subsemigroup `M` of the magma `M`."]
feat: improve the way to_additive deals with attributes (#1314)
  • The new syntax for any attributes that need to be copied by to_additive is @[to_additive (attrs := simp, ext, simps)]
  • Adds the auxiliary declarations generated by the simp and simps attributes to the to_additive-dictionary.
  • Future issue: Does not yet translate auxiliary declarations for other attributes (including custom simp-attributes). In particular it's possible that norm_cast might generate some auxiliary declarations.
  • Fixes #950
  • Fixes #953
  • Fixes #1149
  • This moves the interaction between to_additive and simps from the Simps file to the toAdditive file for uniformity.
  • Make the same changes to @[reassoc]

Co-authored-by: Johan Commelin <johan@commelin.net> Co-authored-by: Scott Morrison <scott.morrison@gmail.com>

Diff
@@ -116,32 +116,32 @@ def Simps.coe (S : Subsemigroup M) : Set M :=
 initialize_simps_projections Subsemigroup (carrier → coe)
 initialize_simps_projections AddSubsemigroup (carrier → coe)
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem mem_carrier {s : Subsemigroup M} {x : M} : x ∈ s.carrier ↔ x ∈ s :=
   Iff.rfl
 #align subsemigroup.mem_carrier Subsemigroup.mem_carrier
 #align add_subsemigroup.mem_carrier AddSubsemigroup.mem_carrier
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem mem_mk {s : Set M} {x : M} (h_mul) : x ∈ mk s h_mul ↔ x ∈ s :=
   Iff.rfl
 #align subsemigroup.mem_mk Subsemigroup.mem_mk
 #align add_subsemigroup.mem_mk AddSubsemigroup.mem_mk
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem coe_set_mk {s : Set M} (h_mul) : (mk s h_mul : Set M) = s :=
   rfl
 #align subsemigroup.coe_set_mk Subsemigroup.coe_set_mk
 #align add_subsemigroup.coe_set_mk AddSubsemigroup.coe_set_mk
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem mk_le_mk {s t : Set M} (h_mul) (h_mul') : mk s h_mul ≤ mk t h_mul' ↔ s ⊆ t :=
   Iff.rfl
 #align subsemigroup.mk_le_mk Subsemigroup.mk_le_mk
 #align add_subsemigroup.mk_le_mk AddSubsemigroup.mk_le_mk
 
 /-- Two subsemigroups are equal if they have the same elements. -/
-@[ext, to_additive "Two `AddSubsemigroup`s are equal if they have the same elements."]
+@[to_additive (attr := ext) "Two `AddSubsemigroup`s are equal if they have the same elements."]
 theorem ext {S T : Subsemigroup M} (h : ∀ x, x ∈ S ↔ x ∈ T) : S = T :=
   SetLike.ext h
 #align subsemigroup.ext Subsemigroup.ext
@@ -158,7 +158,7 @@ protected def copy (S : Subsemigroup M) (s : Set M) (hs : s = S) :
 
 variable {S : Subsemigroup M}
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem coe_copy {s : Set M} (hs : s = S) : (S.copy s hs : Set M) = s :=
   rfl
 #align subsemigroup.coe_copy Subsemigroup.coe_copy
@@ -201,19 +201,19 @@ theorem not_mem_bot {x : M} : x ∉ (⊥ : Subsemigroup M) :=
 #align subsemigroup.not_mem_bot Subsemigroup.not_mem_bot
 #align add_subsemigroup.not_mem_bot AddSubsemigroup.not_mem_bot
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem mem_top (x : M) : x ∈ (⊤ : Subsemigroup M) :=
   Set.mem_univ x
 #align subsemigroup.mem_top Subsemigroup.mem_top
 #align add_subsemigroup.mem_top AddSubsemigroup.mem_top
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem coe_top : ((⊤ : Subsemigroup M) : Set M) = Set.univ :=
   rfl
 #align subsemigroup.coe_top Subsemigroup.coe_top
 #align add_subsemigroup.coe_top AddSubsemigroup.coe_top
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem coe_bot : ((⊥ : Subsemigroup M) : Set M) = ∅ :=
   rfl
 #align subsemigroup.coe_bot Subsemigroup.coe_bot
@@ -226,13 +226,13 @@ instance : HasInf (Subsemigroup M) :=
     { carrier := S₁ ∩ S₂
       mul_mem' := fun ⟨hx, hx'⟩ ⟨hy, hy'⟩ => ⟨S₁.mul_mem hx hy, S₂.mul_mem hx' hy'⟩ }⟩
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem coe_inf (p p' : Subsemigroup M) : ((p ⊓ p' : Subsemigroup M) : Set M) = (p : Set M) ∩ p' :=
   rfl
 #align subsemigroup.coe_inf Subsemigroup.coe_inf
 #align add_subsemigroup.coe_inf AddSubsemigroup.coe_inf
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem mem_inf {p p' : Subsemigroup M} {x : M} : x ∈ p ⊓ p' ↔ x ∈ p ∧ x ∈ p' :=
   Iff.rfl
 #align subsemigroup.mem_inf Subsemigroup.mem_inf
@@ -246,7 +246,7 @@ instance : InfSet (Subsemigroup M) :=
         Set.mem_binterᵢ fun i h =>
           i.mul_mem (by apply Set.mem_interᵢ₂.1 hx i h) (by apply Set.mem_interᵢ₂.1 hy i h) }⟩
 
-@[simp, norm_cast, to_additive]
+@[to_additive (attr := simp, norm_cast)]
 theorem coe_infₛ (S : Set (Subsemigroup M)) : ((infₛ S : Subsemigroup M) : Set M) = ⋂ s ∈ S, ↑s :=
   rfl
 #align subsemigroup.coe_Inf Subsemigroup.coe_infₛ
@@ -264,7 +264,7 @@ theorem mem_infᵢ {ι : Sort _} {S : ι → Subsemigroup M} {x : M} : (x ∈ 
 #align subsemigroup.mem_infi Subsemigroup.mem_infᵢ
 #align add_subsemigroup.mem_infi AddSubsemigroup.mem_infᵢ
 
-@[simp, norm_cast, to_additive]
+@[to_additive (attr := simp, norm_cast)]
 theorem coe_infᵢ {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i) : Set M) = ⋂ i, S i := by
   simp only [infᵢ, coe_infₛ, Set.binterᵢ_range]
 #align subsemigroup.coe_infi Subsemigroup.coe_infᵢ
@@ -287,7 +287,7 @@ instance : CompleteLattice (Subsemigroup M) :=
     inf_le_left := fun _ _ _ => And.left
     inf_le_right := fun _ _ _ => And.right }
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem subsingleton_of_subsingleton [Subsingleton (Subsemigroup M)] : Subsingleton M := by
   constructor; intro x y
   have : ∀ a : M, a ∈ (⊥ : Subsemigroup M) := by simp [Subsingleton.elim (⊥ : Subsemigroup M) ⊤]
@@ -316,7 +316,7 @@ theorem mem_closure {x : M} : x ∈ closure s ↔ ∀ S : Subsemigroup M, s ⊆
 #align add_subsemigroup.mem_closure AddSubsemigroup.mem_closure
 
 /-- The subsemigroup generated by a set includes the set. -/
-@[simp, to_additive "The `AddSubsemigroup` generated by a set includes the set."]
+@[to_additive (attr := simp) "The `AddSubsemigroup` generated by a set includes the set."]
 theorem subset_closure : s ⊆ closure s := fun _ hx => mem_closure.2 fun _ hS => hS hx
 #align subsemigroup.subset_closure Subsemigroup.subset_closure
 #align add_subsemigroup.subset_closure AddSubsemigroup.subset_closure
@@ -358,7 +358,7 @@ variable (S)
 
 /-- An induction principle for closure membership. If `p` holds for all elements of `s`, and
 is preserved under multiplication, then `p` holds for all elements of the closure of `s`. -/
-@[elab_as_elim, to_additive "An induction principle for additive closure membership. If `p`
+@[to_additive (attr := elab_as_elim) "An induction principle for additive closure membership. If `p`
   holds for all elements of `s`, and is preserved under addition, then `p` holds for all
   elements of the additive closure of `s`."]
 theorem closure_induction {p : M → Prop} {x} (h : x ∈ closure s) (Hs : ∀ x ∈ s, p x)
@@ -368,7 +368,7 @@ theorem closure_induction {p : M → Prop} {x} (h : x ∈ closure s) (Hs : ∀ x
 #align add_subsemigroup.closure_induction AddSubsemigroup.closure_induction
 
 /-- A dependent version of `Subsemigroup.closure_induction`.  -/
-@[elab_as_elim, to_additive "A dependent version of `AddSubsemigroup.closure_induction`. "]
+@[to_additive (attr := elab_as_elim) "A dependent version of `AddSubsemigroup.closure_induction`. "]
 theorem closure_induction' (s : Set M) {p : ∀ x, x ∈ closure s → Prop}
     (Hs : ∀ (x) (h : x ∈ s), p x (subset_closure h))
     (Hmul : ∀ x hx y hy, p x hx → p y hy → p (x * y) (mul_mem hx hy)) {x} (hx : x ∈ closure s) :
@@ -381,7 +381,7 @@ theorem closure_induction' (s : Set M) {p : ∀ x, x ∈ closure s → Prop}
 #align add_subsemigroup.closure_induction' AddSubsemigroup.closure_induction'
 
 /-- An induction principle for closure membership for predicates with two arguments.  -/
-@[elab_as_elim, to_additive "An induction principle for additive closure membership for
+@[to_additive (attr := elab_as_elim) "An induction principle for additive closure membership for
   predicates with two arguments."]
 theorem closure_induction₂ {p : M → M → Prop} {x} {y : M} (hx : x ∈ closure s) (hy : y ∈ closure s)
     (Hs : ∀ x ∈ s, ∀ y ∈ s, p x y) (Hmul_left : ∀ x y z, p x z → p y z → p (x * y) z)
@@ -395,7 +395,7 @@ theorem closure_induction₂ {p : M → M → Prop} {x} {y : M} (hx : x ∈ clos
 /-- If `s` is a dense set in a magma `M`, `Subsemigroup.closure s = ⊤`, then in order to prove that
 some predicate `p` holds for all `x : M` it suffices to verify `p x` for `x ∈ s`,
 and verify that `p x` and `p y` imply `p (x * y)`. -/
-@[elab_as_elim, to_additive "If `s` is a dense set in an additive monoid `M`,
+@[to_additive (attr := elab_as_elim) "If `s` is a dense set in an additive monoid `M`,
   `AddSubsemigroup.closure s = ⊤`, then in order to prove that some predicate `p` holds
   for all `x : M` it suffices to verify `p x` for `x ∈ s`, and verify that `p x` and `p y` imply
   `p (x + y)`."]
@@ -418,19 +418,19 @@ protected def gi : GaloisInsertion (@closure M _) SetLike.coe :=
 variable {M}
 
 /-- Closure of a subsemigroup `S` equals `S`. -/
-@[simp, to_additive "Additive closure of an additive subsemigroup `S` equals `S`"]
+@[to_additive (attr := simp) "Additive closure of an additive subsemigroup `S` equals `S`"]
 theorem closure_eq : closure (S : Set M) = S :=
   (Subsemigroup.gi M).l_u_eq S
 #align subsemigroup.closure_eq Subsemigroup.closure_eq
 #align add_subsemigroup.closure_eq AddSubsemigroup.closure_eq
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem closure_empty : closure (∅ : Set M) = ⊥ :=
   (Subsemigroup.gi M).gc.l_bot
 #align subsemigroup.closure_empty Subsemigroup.closure_empty
 #align add_subsemigroup.closure_empty AddSubsemigroup.closure_empty
 
-@[simp, to_additive]
+@[to_additive (attr := simp)]
 theorem closure_univ : closure (univ : Set M) = ⊤ :=
   @coe_top M _ ▸ closure_eq ⊤
 #align subsemigroup.closure_univ Subsemigroup.closure_univ
@@ -536,7 +536,7 @@ semigroup.  Then `AddHom.ofDense` defines an additive homomorphism from `M` aski
 of `f (x + y) = f x + f y` only for `y ∈ s`. -/
 add_decl_doc AddHom.ofDense
 
-@[simp, norm_cast, to_additive]
+@[to_additive (attr := simp, norm_cast)]
 theorem coe_ofDense [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : closure s = ⊤)
     (hmul) : (ofDense f hs hmul : M → N) = f :=
   rfl
chore: fix more casing errors per naming scheme (#1232)

I've avoided anything under Tactic or test.

In correcting the names, I found Option.isNone_iff_eq_none duplicated between Std and Mathlib, so the Mathlib one has been removed.

Co-authored-by: Reid Barton <rwbarton@gmail.com>

Diff
@@ -107,7 +107,7 @@ instance : SetLike (Subsemigroup M) M :=
 instance : MulMemClass (Subsemigroup M) M where mul_mem := fun {_ _ _} => Subsemigroup.mul_mem' _
 
 /-- See Note [custom simps projection] -/
-@[to_additive " See Note [custom simps projection]"]
+@[to_additive "See Note [custom simps projection]"]
 def Simps.coe (S : Subsemigroup M) : Set M :=
   S
 #align subsemigroup.simps.coe Subsemigroup.Simps.coe
feat: port GroupTheory.Subsemigroup.Operations (#1235)

Co-authored-by: Chris Hughes <33847686+ChrisHughes24@users.noreply.github.com>

Diff
@@ -62,7 +62,7 @@ variable [Mul M] {s : Set M}
 variable [Add A] {t : Set A}
 
 /-- `MulMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(*)` -/
-class MulMemClass (S : Type _) (M : outParam <| Type _) [Mul M] [SetLike S M] where
+class MulMemClass (S : Type _) (M : outParam <| Type _) [Mul M] [SetLike S M] : Prop where
   /-- A substructure satisfying `MulMemClass` is closed under multiplication. -/
   mul_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a * b ∈ s
 #align mul_mem_class MulMemClass
@@ -70,7 +70,7 @@ class MulMemClass (S : Type _) (M : outParam <| Type _) [Mul M] [SetLike S M] wh
 export MulMemClass (mul_mem)
 
 /-- `AddMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(+)` -/
-class AddMemClass (S : Type _) (M : outParam <| Type _) [Add M] [SetLike S M] where
+class AddMemClass (S : Type _) (M : outParam <| Type _) [Add M] [SetLike S M] : Prop where
   /-- A substructure satisfying `AddMemClass` is closed under addition. -/
   add_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a + b ∈ s
 #align add_mem_class AddMemClass
chore: tidy various files (#1247)

Co-authored-by: ChrisHughes24 <chrishughes24@gmail.com>

Diff
@@ -17,7 +17,7 @@ import Mathlib.Data.SetLike.Basic
 # Subsemigroups: definition and `complete_lattice` structure
 
 This file defines bundled multiplicative and additive subsemigroups. We also define
-a `complete_lattice` structure on `Subsemigroup`s,
+a `CompleteLattice` structure on `Subsemigroup`s,
 and define the closure of a set as the minimal subsemigroup that includes this set.
 
 ## Main definitions
@@ -52,7 +52,6 @@ subsemigroup, subsemigroups
 -/
 
 
--- Only needed for notation
 -- Only needed for notation
 variable {M : Type _} {N : Type _} {A : Type _}
 
@@ -70,7 +69,7 @@ class MulMemClass (S : Type _) (M : outParam <| Type _) [Mul M] [SetLike S M] wh
 
 export MulMemClass (mul_mem)
 
-/-- `add_mem_class S M` says `S` is a type of sets `s : Set M` that are closed under `(+)` -/
+/-- `AddMemClass S M` says `S` is a type of sets `s : Set M` that are closed under `(+)` -/
 class AddMemClass (S : Type _) (M : outParam <| Type _) [Add M] [SetLike S M] where
   /-- A substructure satisfying `AddMemClass` is closed under addition. -/
   add_mem : ∀ {s : S} {a b : M}, a ∈ s → b ∈ s → a + b ∈ s
@@ -142,14 +141,14 @@ theorem mk_le_mk {s t : Set M} (h_mul) (h_mul') : mk s h_mul ≤ mk t h_mul' ↔
 #align add_subsemigroup.mk_le_mk AddSubsemigroup.mk_le_mk
 
 /-- Two subsemigroups are equal if they have the same elements. -/
-@[ext, to_additive "Two `add_subsemigroup`s are equal if they have the same elements."]
+@[ext, to_additive "Two `AddSubsemigroup`s are equal if they have the same elements."]
 theorem ext {S T : Subsemigroup M} (h : ∀ x, x ∈ S ↔ x ∈ T) : S = T :=
   SetLike.ext h
 #align subsemigroup.ext Subsemigroup.ext
 #align add_subsemigroup.ext AddSubsemigroup.ext
 
 /-- Copy a subsemigroup replacing `carrier` with a set that is equal to it. -/
-@[to_additive "Copy an additive subsemigroup replacing `carrier` with a set that is equal to\nit."]
+@[to_additive "Copy an additive subsemigroup replacing `carrier` with a set that is equal to it."]
 protected def copy (S : Subsemigroup M) (s : Set M) (hs : s = S) :
     Subsemigroup M where
   carrier := s
@@ -174,7 +173,7 @@ theorem copy_eq {s : Set M} (hs : s = S) : S.copy s hs = S :=
 variable (S)
 
 /-- A subsemigroup is closed under multiplication. -/
-@[to_additive "An `add_subsemigroup` is closed under addition."]
+@[to_additive "An `AddSubsemigroup` is closed under addition."]
 protected theorem mul_mem {x y : M} : x ∈ S → y ∈ S → x * y ∈ S :=
   Subsemigroup.mul_mem' S
 #align subsemigroup.mul_mem Subsemigroup.mul_mem
@@ -187,7 +186,7 @@ instance : Top (Subsemigroup M) :=
       mul_mem' := fun _ _ => Set.mem_univ _ }⟩
 
 /-- The trivial subsemigroup `∅` of a magma `M`. -/
-@[to_additive "The trivial `add_subsemigroup` `∅` of an additive magma `M`."]
+@[to_additive "The trivial `AddSubsemigroup` `∅` of an additive magma `M`."]
 instance : Bot (Subsemigroup M) :=
   ⟨{  carrier := ∅
       mul_mem' := False.elim }⟩
@@ -221,7 +220,7 @@ theorem coe_bot : ((⊥ : Subsemigroup M) : Set M) = ∅ :=
 #align add_subsemigroup.coe_bot AddSubsemigroup.coe_bot
 
 /-- The inf of two subsemigroups is their intersection. -/
-@[to_additive "The inf of two `add_subsemigroup`s is their intersection."]
+@[to_additive "The inf of two `AddSubsemigroup`s is their intersection."]
 instance : HasInf (Subsemigroup M) :=
   ⟨fun S₁ S₂ =>
     { carrier := S₁ ∩ S₂
@@ -272,7 +271,7 @@ theorem coe_infᵢ {ι : Sort _} {S : ι → Subsemigroup M} : (↑(⨅ i, S i)
 #align add_subsemigroup.coe_infi AddSubsemigroup.coe_infᵢ
 
 /-- subsemigroups of a monoid form a complete lattice. -/
-@[to_additive "The `add_subsemigroup`s of an `add_monoid` form a complete lattice."]
+@[to_additive "The `AddSubsemigroup`s of an `AddMonoid` form a complete lattice."]
 instance : CompleteLattice (Subsemigroup M) :=
   { completeLatticeOfInf (Subsemigroup M) fun _ =>
       IsGLB.of_image SetLike.coe_subset_coe isGLB_binfᵢ with
@@ -303,8 +302,8 @@ instance [hn : Nonempty M] : Nontrivial (Subsemigroup M) :=
       refine' absurd (_ : x ∈ ⊥) not_mem_bot
       simp [h]⟩⟩
 
-/-- The `subsemigroup` generated by a set. -/
-@[to_additive "The `add_subsemigroup` generated by a set"]
+/-- The `Subsemigroup` generated by a set. -/
+@[to_additive "The `AddSubsemigroup` generated by a set"]
 def closure (s : Set M) : Subsemigroup M :=
   infₛ { S | s ⊆ S }
 #align subsemigroup.closure Subsemigroup.closure
@@ -317,7 +316,7 @@ theorem mem_closure {x : M} : x ∈ closure s ↔ ∀ S : Subsemigroup M, s ⊆
 #align add_subsemigroup.mem_closure AddSubsemigroup.mem_closure
 
 /-- The subsemigroup generated by a set includes the set. -/
-@[simp, to_additive "The `add_subsemigroup` generated by a set includes the set."]
+@[simp, to_additive "The `AddSubsemigroup` generated by a set includes the set."]
 theorem subset_closure : s ⊆ closure s := fun _ hx => mem_closure.2 fun _ hS => hS hx
 #align subsemigroup.subset_closure Subsemigroup.subset_closure
 #align add_subsemigroup.subset_closure AddSubsemigroup.subset_closure
@@ -334,7 +333,7 @@ open Set
 
 /-- A subsemigroup `S` includes `closure s` if and only if it includes `s`. -/
 @[simp,
-  to_additive "An additive subsemigroup `S` includes `closure s`\nif and only if it includes `s`"]
+  to_additive "An additive subsemigroup `S` includes `closure s` if and only if it includes `s`"]
 theorem closure_le : closure s ≤ S ↔ s ⊆ S :=
   ⟨Subset.trans subset_closure, fun h => infₛ_le h⟩
 #align subsemigroup.closure_le Subsemigroup.closure_le
@@ -480,8 +479,7 @@ open Subsemigroup
 
 /-- The subsemigroup of elements `x : M` such that `f x = g x` -/
 @[to_additive "The additive subsemigroup of elements `x : M` such that `f x = g x`"]
-def eqLocus (f g : M →ₙ* N) :
-    Subsemigroup M where
+def eqLocus (f g : M →ₙ* N) : Subsemigroup M where
   carrier := { x | f x = g x }
   mul_mem' (hx : _ = _) (hy : _ = _) := by simp [*]
 #align mul_hom.eq_mlocus MulHom.eqLocus
feat: port GroupTheory/Submonoid/Basic (#1224)

Co-authored-by: Yury G. Kudryashov <urkud@urkud.name>

Diff
@@ -151,7 +151,7 @@ theorem ext {S T : Subsemigroup M} (h : ∀ x, x ∈ S ↔ x ∈ T) : S = T :=
 /-- Copy a subsemigroup replacing `carrier` with a set that is equal to it. -/
 @[to_additive "Copy an additive subsemigroup replacing `carrier` with a set that is equal to\nit."]
 protected def copy (S : Subsemigroup M) (s : Set M) (hs : s = S) :
-    Subsemigroup M where 
+    Subsemigroup M where
   carrier := s
   mul_mem' := hs.symm ▸ S.mul_mem'
 #align subsemigroup.copy Subsemigroup.copy
@@ -298,7 +298,7 @@ theorem subsingleton_of_subsingleton [Subsingleton (Subsemigroup M)] : Subsingle
 
 @[to_additive]
 instance [hn : Nonempty M] : Nontrivial (Subsemigroup M) :=
-  ⟨⟨⊥, ⊤, fun h => by 
+  ⟨⟨⊥, ⊤, fun h => by
       obtain ⟨x⟩ := id hn
       refine' absurd (_ : x ∈ ⊥) not_mem_bot
       simp [h]⟩⟩
@@ -373,7 +373,7 @@ theorem closure_induction {p : M → Prop} {x} (h : x ∈ closure s) (Hs : ∀ x
 theorem closure_induction' (s : Set M) {p : ∀ x, x ∈ closure s → Prop}
     (Hs : ∀ (x) (h : x ∈ s), p x (subset_closure h))
     (Hmul : ∀ x hx y hy, p x hx → p y hy → p (x * y) (mul_mem hx hy)) {x} (hx : x ∈ closure s) :
-    p x hx := by 
+    p x hx := by
   refine' Exists.elim _ fun (hx : x ∈ closure s) (hc : p x hx) => hc
   exact
     closure_induction hx (fun x hx => ⟨_, Hs x hx⟩) fun x y ⟨hx', hx⟩ ⟨hy', hy⟩ =>
@@ -446,8 +446,8 @@ theorem closure_union (s t : Set M) : closure (s ∪ t) = closure s ⊔ closure
 @[to_additive]
 theorem closure_unionᵢ {ι} (s : ι → Set M) : closure (⋃ i, s i) = ⨆ i, closure (s i) :=
   (Subsemigroup.gi M).gc.l_supᵢ
-#align subsemigroup.closure_Union Subsemigroup.closure_unionᵢ 
-#align add_subsemigroup.closure_Union AddSubsemigroup.closure_unionᵢ 
+#align subsemigroup.closure_Union Subsemigroup.closure_unionᵢ
+#align add_subsemigroup.closure_Union AddSubsemigroup.closure_unionᵢ
 
 @[to_additive]
 theorem closure_singleton_le_iff_mem (m : M) (p : Subsemigroup M) : closure {m} ≤ p ↔ m ∈ p := by
@@ -481,7 +481,7 @@ open Subsemigroup
 /-- The subsemigroup of elements `x : M` such that `f x = g x` -/
 @[to_additive "The additive subsemigroup of elements `x : M` such that `f x = g x`"]
 def eqLocus (f g : M →ₙ* N) :
-    Subsemigroup M where 
+    Subsemigroup M where
   carrier := { x | f x = g x }
   mul_mem' (hx : _ = _) (hy : _ = _) := by simp [*]
 #align mul_hom.eq_mlocus MulHom.eqLocus
@@ -490,24 +490,24 @@ def eqLocus (f g : M →ₙ* N) :
 /-- If two mul homomorphisms are equal on a set, then they are equal on its subsemigroup closure. -/
 @[to_additive "If two add homomorphisms are equal on a set,
   then they are equal on its additive subsemigroup closure."]
-theorem eq_on_closure {f g : M →ₙ* N} {s : Set M} (h : Set.EqOn f g s) :
+theorem eqOn_closure {f g : M →ₙ* N} {s : Set M} (h : Set.EqOn f g s) :
     Set.EqOn f g (closure s) :=
   show closure s ≤ f.eqLocus g from closure_le.2 h
-#align mul_hom.eq_on_mclosure MulHom.eq_on_closure
-#align add_hom.eq_on_mclosure AddHom.eq_on_closure
+#align mul_hom.eq_on_mclosure MulHom.eqOn_closure
+#align add_hom.eq_on_mclosure AddHom.eqOn_closure
 
 @[to_additive]
-theorem eq_of_eq_on_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup M)) : f = g :=
+theorem eq_of_eqOn_top {f g : M →ₙ* N} (h : Set.EqOn f g (⊤ : Subsemigroup M)) : f = g :=
   ext fun _ => h trivial
-#align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eq_on_top
-#align add_hom.eq_of_eq_on_mtop AddHom.eq_of_eq_on_top
+#align mul_hom.eq_of_eq_on_mtop MulHom.eq_of_eqOn_top
+#align add_hom.eq_of_eq_on_mtop AddHom.eq_of_eqOn_top
 
 @[to_additive]
-theorem eq_of_eq_on_dense {s : Set M} (hs : closure s = ⊤) {f g : M →ₙ* N} (h : s.EqOn f g) :
+theorem eq_of_eqOn_dense {s : Set M} (hs : closure s = ⊤) {f g : M →ₙ* N} (h : s.EqOn f g) :
     f = g :=
-  eq_of_eq_on_top <| hs ▸ eq_on_closure h
-#align mul_hom.eq_of_eq_on_mdense MulHom.eq_of_eq_on_dense
-#align add_hom.eq_of_eq_on_mdense AddHom.eq_of_eq_on_dense
+  eq_of_eqOn_top <| hs ▸ eqOn_closure h
+#align mul_hom.eq_of_eq_on_mdense MulHom.eq_of_eqOn_dense
+#align add_hom.eq_of_eq_on_mdense AddHom.eq_of_eqOn_dense
 
 end MulHom
 
@@ -525,7 +525,7 @@ of `f (x * y) = f x * f y` only for `y ∈ s`. -/
 @[to_additive]
 def ofDense {M N} [Semigroup M] [Semigroup N] {s : Set M} (f : M → N) (hs : closure s = ⊤)
     (hmul : ∀ (x), ∀ y ∈ s, f (x * y) = f x * f y) :
-    M →ₙ* N where 
+    M →ₙ* N where
   toFun := f
   map_mul' x y :=
     dense_induction y hs (fun y hy x => hmul x y hy)
Feat: port GroupTheory.Subsemigroup.Basic (#1180)

.

Co-authored-by: Chris Hughes <33847686+ChrisHughes24@users.noreply.github.com>

Dependencies 65

66 files ported (100.0%)
37338 lines ported (100.0%)

All dependencies are ported!