Skip to content

Commit 1c97f0e

Browse files
committed
chore(Topology/Sheaves/SheafCondition/PairwiseIntersections): remove an erw (leanprover-community#38508)
- rewrites `interUnionPullbackConeLift_left` and `interUnionPullbackConeLift_right` by unfolding `interUnionPullbackConeLift` directly in the `rw` chain - rewrites the two `isLimitPullbackCone` branches by adding `Functor.mapCone_π_app` to the `rw` chain instead of using `erw [← F.1.map_comp]` Extracted from leanprover-community#38415 [![Open in Gitpod](https://gitpod.io/button/open-in-gitpod.svg)](https://gitpod.io/from-referrer/)
1 parent 6bc8824 commit 1c97f0e

1 file changed

Lines changed: 5 additions & 9 deletions

File tree

Mathlib/Topology/Sheaves/SheafCondition/PairwiseIntersections.lean

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -371,17 +371,15 @@ def interUnionPullbackConeLift : s.pt ⟶ F.1.obj (op (U ⊔ V)) := by
371371
set_option backward.isDefEq.respectTransparency false in
372372
theorem interUnionPullbackConeLift_left :
373373
interUnionPullbackConeLift F U V s ≫ F.1.map (homOfLE le_sup_left).op = s.fst := by
374-
erw [Category.assoc]
375-
simp_rw [← F.1.map_comp]
374+
rw [interUnionPullbackConeLift, Category.assoc, ← F.1.map_comp]
376375
exact
377376
(F.presheaf.isSheaf_iff_isSheafPairwiseIntersections.mp F.2 _).some.fac _ <|
378377
op <| Pairwise.single <| ULift.up WalkingPair.left
379378

380379
set_option backward.isDefEq.respectTransparency false in
381380
theorem interUnionPullbackConeLift_right :
382381
interUnionPullbackConeLift F U V s ≫ F.1.map (homOfLE le_sup_right).op = s.snd := by
383-
erw [Category.assoc]
384-
simp_rw [← F.1.map_comp]
382+
rw [interUnionPullbackConeLift, Category.assoc, ← F.1.map_comp]
385383
exact
386384
(F.presheaf.isSheaf_iff_isSheafPairwiseIntersections.mp F.2 _).some.fac _ <|
387385
op <| Pairwise.single <| ULift.up WalkingPair.right
@@ -408,12 +406,10 @@ def isLimitPullbackCone : IsLimit (interUnionPullbackCone F U V) := by
408406
rw [← cancel_mono (F.1.map (eqToHom hι.symm).op)]
409407
apply (F.presheaf.isSheaf_iff_isSheafPairwiseIntersections.mp F.2 ι).some.hom_ext
410408
rintro ((_ | _) | (_ | _)) <;>
411-
rw [Category.assoc, Category.assoc]
412-
· erw [← F.1.map_comp]
413-
convert h₁
409+
rw [Category.assoc, Category.assoc, Functor.mapCone_π_app, ← F.1.map_comp]
410+
· convert h₁
414411
apply interUnionPullbackConeLift_left
415-
· erw [← F.1.map_comp]
416-
convert h₂
412+
· convert h₂
417413
apply interUnionPullbackConeLift_right
418414
all_goals
419415
dsimp only [Functor.op, Pairwise.cocone_ι_app, Functor.mapCone_π_app, Cocone.op,

0 commit comments

Comments
 (0)