Skip to content

Commit 1e78022

Browse files
committed
chore: mark WidePushoutShape.wideSpan as implicit_reducible (#42722)
This PR marks `CategoryTheory.Limits.WidePushoutShape.wideSpan`/`wideCospan` as `implicit_reducible`, because a lot of declarations depend on unfolding them.
1 parent 9535344 commit 1e78022

4 files changed

Lines changed: 3 additions & 18 deletions

File tree

Mathlib/Algebra/Category/Ring/Constructions.lean

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -484,7 +484,7 @@ instance pullbackFst_isLocalHom (f : A ⟶ C) (g : B ⟶ C) [IsLocalHom g.hom] :
484484
IsLocalHom (pullback.fst f g).hom := by
485485
refine Limits.π_isLocalHom _ (limit.isLimit _) left fun x hx i ↦ ?_
486486
rcases i with _ | _ | _
487-
· exact ⟨one, 𝟙 _, Hom.inl, inferInstance, by simp; rfl
487+
· exact ⟨one, 𝟙 _, Hom.inl, inferInstance, by simp⟩
488488
· exact ⟨left, 𝟙 _, 𝟙 _, inferInstance, by simp⟩
489489
· refine ⟨one, Hom.inr, Hom.inl, ‹_›, ?_⟩
490490
exact DFunLike.congr_fun (congr(Hom.hom $(pullback.condition (f := f) (g := g)))) x |>.symm

Mathlib/AlgebraicTopology/CechNerve.lean

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -349,15 +349,12 @@ variable [HasTerminal C] (ι : Type w)
349349
def wideCospan (X : C) : WidePullbackShape ι ⥤ C :=
350350
WidePullbackShape.wideCospan (terminal C) (fun _ : ι => X) fun _ => terminal.from X
351351

352-
set_option backward.defeqAttrib.useBackward true in
353352
instance uniqueToWideCospanNone (X Y : C) : Unique (Y ⟶ (wideCospan ι X).obj none) := by
354353
dsimp [wideCospan]
355354
infer_instance
356355

357356
variable [HasFiniteProducts C]
358357

359-
set_option backward.defeqAttrib.useBackward true in
360-
set_option backward.isDefEq.respectTransparency false in
361358
/-- The product `Xᶥ` is the vertex of a limit cone on `wideCospan ι X`. -/
362359
def wideCospan.limitCone [Finite ι] (X : C) : LimitCone (wideCospan ι X) where
363360
cone :=
@@ -412,7 +409,6 @@ lemma wideCospan.limitIsoPi_hom_comp_pi [Finite ι] (X : C) (j : ι) :
412409
(wideCospan.limitIsoPi ι X).hom ≫ Pi.π _ j = WidePullback.π _ j := by
413410
rw [← wideCospan.limitIsoPi_inv_comp_pi, Iso.hom_inv_id_assoc]
414411

415-
set_option backward.defeqAttrib.useBackward true in
416412
set_option backward.isDefEq.respectTransparency false in
417413
/-- Given an object `X : C`, the Čech nerve of the hom to the terminal object `X ⟶ ⊤_ C` is
418414
naturally isomorphic to a simplicial object sending `⦋n⦌` to `Xⁿ⁺¹` (when `C` is `G-Set`, this is

Mathlib/CategoryTheory/Limits/Shapes/ConcreteCategory.lean

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -348,10 +348,8 @@ theorem widePushout_exists_rep {B : C} {α : Type _} {X : α → C} (f : ∀ j :
348348
obtain ⟨_ | j, y, rfl⟩ := Concrete.colimit_exists_rep _ x
349349
· left
350350
use y
351-
rfl
352351
· right
353352
use j, y
354-
rfl
355353

356354
theorem widePushout_exists_rep' {B : C} {α : Type _} [Nonempty α] {X : α → C}
357355
(f : ∀ j : α, B ⟶ X j) [HasWidePushout.{v} B X f] [PreservesColimit (wideSpan B X f) (forget C)]

Mathlib/CategoryTheory/Limits/Shapes/WidePullbacks.lean

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -107,22 +107,19 @@ variable {C : Type u} [Category.{v} C]
107107
/-- Construct a functor out of the wide pullback shape given a J-indexed collection of arrows to a
108108
fixed object.
109109
-/
110-
@[simps]
110+
@[simps, implicit_reducible]
111111
def wideCospan (B : C) (objs : J → C) (arrows : ∀ j : J, objs j ⟶ B) : WidePullbackShape J ⥤ C where
112112
obj j := Option.casesOn j B objs
113113
map f := by
114114
obtain - | j := f
115115
· apply 𝟙 _
116116
· exact arrows j
117117

118-
set_option backward.isDefEq.respectTransparency.types false in
119-
set_option backward.defeqAttrib.useBackward true in
120118
/-- Every diagram is naturally isomorphic (actually, equal) to a `wideCospan` -/
121119
def diagramIsoWideCospan (F : WidePullbackShape J ⥤ C) :
122120
F ≅ wideCospan (F.obj none) (fun j => F.obj (some j)) fun j => F.map (Hom.term j) :=
123121
NatIso.ofComponents fun j => eqToIso <| by cat_disch
124122

125-
set_option backward.defeqAttrib.useBackward true in
126123
/-- Construct a cone over a wide cospan. -/
127124
@[simps]
128125
def mkCone {F : WidePullbackShape J ⥤ C} {X : C} (f : X ⟶ F.obj none) (π : ∀ j, X ⟶ F.obj (some j))
@@ -233,7 +230,7 @@ variable {C : Type u} [Category.{v} C]
233230
/-- Construct a functor out of the wide pushout shape given a J-indexed collection of arrows from a
234231
fixed object.
235232
-/
236-
@[simps]
233+
@[simps, implicit_reducible]
237234
def wideSpan (B : C) (objs : J → C) (arrows : ∀ j : J, B ⟶ objs j) : WidePushoutShape J ⥤ C where
238235
obj j := Option.casesOn j B objs
239236
map f := by
@@ -246,14 +243,11 @@ def wideSpan (B : C) (objs : J → C) (arrows : ∀ j : J, B ⟶ objs j) : WideP
246243
· cases g
247244
simp only [hom_id, Category.comp_id]; congr
248245

249-
set_option backward.isDefEq.respectTransparency.types false in
250-
set_option backward.defeqAttrib.useBackward true in
251246
/-- Every diagram is naturally isomorphic (actually, equal) to a `wideSpan` -/
252247
def diagramIsoWideSpan (F : WidePushoutShape J ⥤ C) :
253248
F ≅ wideSpan (F.obj none) (fun j => F.obj (some j)) fun j => F.map (Hom.init j) :=
254249
NatIso.ofComponents fun j => eqToIso <| by cases j; repeat rfl
255250

256-
set_option backward.defeqAttrib.useBackward true in
257251
/-- Construct a cocone over a wide span. -/
258252
@[simps]
259253
def mkCocone {F : WidePushoutShape J ⥤ C} {X : C} (f : F.obj none ⟶ X) (ι : ∀ j, F.obj (some j) ⟶ X)
@@ -393,8 +387,6 @@ def π (s : WidePullbackCone f) (i : ι) : s.pt ⟶ Y i :=
393387
def base (s : WidePullbackCone f) : s.pt ⟶ X :=
394388
(Cone.π s).app none
395389

396-
set_option backward.isDefEq.respectTransparency.types false in
397-
set_option backward.defeqAttrib.useBackward true in
398390
@[reassoc (attr := simp)]
399391
lemma condition (s : WidePullbackCone f) (i : ι) : s.π i ≫ f i = s.base := by
400392
simpa using! ((Cone.π s).naturality (.term i)).symm
@@ -482,7 +474,6 @@ lemma reindex_π {ι : Type*} {X : C} {Y : ι → C} {f : ∀ i, Y i ⟶ X} (s :
482474
{ι' : Type*} (e : ι' ≃ ι) (i : ι') :
483475
(s.reindex e).π i = s.π (e i) := rfl
484476

485-
set_option backward.defeqAttrib.useBackward true in
486477
set_option backward.isDefEq.respectTransparency false in
487478
/-- Reindexing a pullback cone preserves being limiting. -/
488479
def reindexIsLimitEquiv {ι : Type*} {X : C} {Y : ι → C} {f : ∀ i, Y i ⟶ X}

0 commit comments

Comments
 (0)