category_theory.category.PartialFunMathlib.CategoryTheory.Category.PartialFun

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)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(no changes)

(last sync)

Changes in mathlib3port

mathlib3
mathlib3port
Diff
@@ -102,7 +102,7 @@ def typeToPartialFun : Type u ⥤ PartialFun
 #align Type_to_PartialFun typeToPartialFun
 -/
 
-instance : Faithful typeToPartialFun :=
+instance : CategoryTheory.Functor.Faithful typeToPartialFun :=
   ⟨fun X Y => PFun.lift_injective⟩
 
 #print pointedToPartialFun /-
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
 -/
 import CategoryTheory.Category.Pointed
-import Data.Pfun
+import Data.PFun
 
 #align_import category_theory.category.PartialFun from "leanprover-community/mathlib"@"1b089e3bdc3ce6b39cd472543474a0a137128c6c"
 
Diff
@@ -135,7 +135,14 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun
 pointed types. This the noncomputable part of the equivalence `PartialFun_equiv_Pointed`. It can't
 be computable because `= option.none` is decidable while the domain of a general `part` isn't. -/
 @[simps map]
-noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by classical
+noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
+  classical exact
+    { obj := fun X => ⟨Option X, none⟩
+      map := fun X Y f => ⟨Option.elim' none fun a => (f a).toOption, rfl⟩
+      map_id' := fun X =>
+        Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.some_toOption _
+      map_comp' := fun X Y Z f g =>
+        Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.bind_toOption _ _ }
 #align PartialFun_to_Pointed partialFunToPointed
 -/
 
@@ -143,7 +150,55 @@ noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by classical
 /-- The equivalence induced by `PartialFun_to_Pointed` and `Pointed_to_PartialFun`.
 `part.equiv_option` made functorial. -/
 @[simps]
-noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed := by classical
+noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed := by
+  classical exact
+    equivalence.mk partialFunToPointed pointedToPartialFun
+      (nat_iso.of_components
+        (fun X =>
+          PartialFun.Iso.mk
+            { toFun := fun a => ⟨some a, some_ne_none a⟩
+              invFun := fun a => get <| ne_none_iff_is_some.1 a.2
+              left_inv := fun a => get_some _ _
+              right_inv := fun a => by simp only [Subtype.val_eq_coe, some_get, Subtype.coe_eta] })
+        fun X Y f =>
+        PFun.ext fun a b => by
+          unfold_projs
+          dsimp
+          rw [Part.bind_some]
+          refine' (part.mem_bind_iff.trans _).trans pfun.mem_to_subtype_iff.symm
+          obtain ⟨b | b, hb⟩ := b
+          · exact (hb rfl).elim
+          dsimp
+          simp_rw [Part.mem_some_iff, Subtype.mk_eq_mk, exists_prop, some_inj, exists_eq_right']
+          refine' part.mem_to_option.symm.trans _
+          exact eq_comm)
+      (nat_iso.of_components
+        (fun X =>
+          Pointed.Iso.mk
+            { toFun := Option.elim' X.point Subtype.val
+              invFun := fun a => if h : a = X.point then none else some ⟨_, h⟩
+              left_inv := fun a =>
+                Option.recOn a (dif_pos rfl) fun a =>
+                  (dif_neg a.2).trans <| by
+                    simp only [Option.elim', Subtype.val_eq_coe, Subtype.coe_eta]
+              right_inv := fun a => by
+                change Option.elim' _ _ (dite _ _ _) = _
+                split_ifs
+                · rw [h]; rfl
+                · rfl }
+            rfl)
+        fun X Y f =>
+        Pointed.Hom.ext _ _ <|
+          funext fun a =>
+            Option.recOn a f.map_point.symm fun a =>
+              by
+              unfold_projs
+              dsimp
+              change Option.elim' _ _ _ = _
+              rw [Part.elim_toOption]
+              split_ifs
+              · rfl
+              · exact Eq.symm (of_not_not h))
 #align PartialFun_equiv_Pointed partialFunEquivPointed
 -/
 
Diff
@@ -135,14 +135,7 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun
 pointed types. This the noncomputable part of the equivalence `PartialFun_equiv_Pointed`. It can't
 be computable because `= option.none` is decidable while the domain of a general `part` isn't. -/
 @[simps map]
-noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
-  classical exact
-    { obj := fun X => ⟨Option X, none⟩
-      map := fun X Y f => ⟨Option.elim' none fun a => (f a).toOption, rfl⟩
-      map_id' := fun X =>
-        Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.some_toOption _
-      map_comp' := fun X Y Z f g =>
-        Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.bind_toOption _ _ }
+noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by classical
 #align PartialFun_to_Pointed partialFunToPointed
 -/
 
@@ -150,55 +143,7 @@ noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
 /-- The equivalence induced by `PartialFun_to_Pointed` and `Pointed_to_PartialFun`.
 `part.equiv_option` made functorial. -/
 @[simps]
-noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed := by
-  classical exact
-    equivalence.mk partialFunToPointed pointedToPartialFun
-      (nat_iso.of_components
-        (fun X =>
-          PartialFun.Iso.mk
-            { toFun := fun a => ⟨some a, some_ne_none a⟩
-              invFun := fun a => get <| ne_none_iff_is_some.1 a.2
-              left_inv := fun a => get_some _ _
-              right_inv := fun a => by simp only [Subtype.val_eq_coe, some_get, Subtype.coe_eta] })
-        fun X Y f =>
-        PFun.ext fun a b => by
-          unfold_projs
-          dsimp
-          rw [Part.bind_some]
-          refine' (part.mem_bind_iff.trans _).trans pfun.mem_to_subtype_iff.symm
-          obtain ⟨b | b, hb⟩ := b
-          · exact (hb rfl).elim
-          dsimp
-          simp_rw [Part.mem_some_iff, Subtype.mk_eq_mk, exists_prop, some_inj, exists_eq_right']
-          refine' part.mem_to_option.symm.trans _
-          exact eq_comm)
-      (nat_iso.of_components
-        (fun X =>
-          Pointed.Iso.mk
-            { toFun := Option.elim' X.point Subtype.val
-              invFun := fun a => if h : a = X.point then none else some ⟨_, h⟩
-              left_inv := fun a =>
-                Option.recOn a (dif_pos rfl) fun a =>
-                  (dif_neg a.2).trans <| by
-                    simp only [Option.elim', Subtype.val_eq_coe, Subtype.coe_eta]
-              right_inv := fun a => by
-                change Option.elim' _ _ (dite _ _ _) = _
-                split_ifs
-                · rw [h]; rfl
-                · rfl }
-            rfl)
-        fun X Y f =>
-        Pointed.Hom.ext _ _ <|
-          funext fun a =>
-            Option.recOn a f.map_point.symm fun a =>
-              by
-              unfold_projs
-              dsimp
-              change Option.elim' _ _ _ = _
-              rw [Part.elim_toOption]
-              split_ifs
-              · rfl
-              · exact Eq.symm (of_not_not h))
+noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed := by classical
 #align PartialFun_equiv_Pointed partialFunEquivPointed
 -/
 
Diff
@@ -3,8 +3,8 @@ Copyright (c) 2022 Yaël Dillies. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
 -/
-import Mathbin.CategoryTheory.Category.Pointed
-import Mathbin.Data.Pfun
+import CategoryTheory.Category.Pointed
+import Data.Pfun
 
 #align_import category_theory.category.PartialFun from "leanprover-community/mathlib"@"1b089e3bdc3ce6b39cd472543474a0a137128c6c"
 
Diff
@@ -2,15 +2,12 @@
 Copyright (c) 2022 Yaël Dillies. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
-
-! This file was ported from Lean 3 source module category_theory.category.PartialFun
-! leanprover-community/mathlib commit 1b089e3bdc3ce6b39cd472543474a0a137128c6c
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathbin.CategoryTheory.Category.Pointed
 import Mathbin.Data.Pfun
 
+#align_import category_theory.category.PartialFun from "leanprover-community/mathlib"@"1b089e3bdc3ce6b39cd472543474a0a137128c6c"
+
 /-!
 # The category of types with partial functions
 
Diff
@@ -4,7 +4,7 @@ Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
 
 ! This file was ported from Lean 3 source module category_theory.category.PartialFun
-! leanprover-community/mathlib commit 14b69e9f3c16630440a2cbd46f1ddad0d561dee7
+! leanprover-community/mathlib commit 1b089e3bdc3ce6b39cd472543474a0a137128c6c
 ! Please do not edit these lines, except to modify the commit id
 ! if you have ported upstream changes.
 -/
@@ -14,6 +14,9 @@ import Mathbin.Data.Pfun
 /-!
 # The category of types with partial functions
 
+> THIS FILE IS SYNCHRONIZED WITH MATHLIB4.
+> Any changes to this file require a corresponding PR to mathlib4.
+
 This defines `PartialFun`, the category of types equipped with partial functions.
 
 This category is classically equivalent to the category of pointed types. The reason it doesn't hold
Diff
@@ -38,21 +38,25 @@ universe u
 
 variable {α β : Type _}
 
+#print PartialFun /-
 /-- The category of types equipped with partial functions. -/
 def PartialFun : Type _ :=
   Type _
 #align PartialFun PartialFun
+-/
 
 namespace PartialFun
 
 instance : CoeSort PartialFun (Type _) :=
   ⟨id⟩
 
+#print PartialFun.of /-
 /-- Turns a type into a `PartialFun`. -/
 @[nolint has_nonempty_instance]
 def of : Type _ → PartialFun :=
   id
 #align PartialFun.of PartialFun.of
+-/
 
 @[simp]
 theorem coe_of (X : Type _) : ↥(of X) = X :=
@@ -62,6 +66,7 @@ theorem coe_of (X : Type _) : ↥(of X) = X :=
 instance : Inhabited PartialFun :=
   ⟨Type _⟩
 
+#print PartialFun.largeCategory /-
 instance largeCategory : LargeCategory.{u} PartialFun
     where
   Hom := PFun
@@ -71,7 +76,9 @@ instance largeCategory : LargeCategory.{u} PartialFun
   comp_id' := @PFun.id_comp
   assoc' W X Y Z _ _ _ := (PFun.comp_assoc _ _ _).symm
 #align PartialFun.large_category PartialFun.largeCategory
+-/
 
+#print PartialFun.Iso.mk /-
 /-- Constructs a partial function isomorphism between types from an equivalence between them. -/
 @[simps]
 def Iso.mk {α β : PartialFun.{u}} (e : α ≃ β) : α ≅ β
@@ -81,9 +88,11 @@ def Iso.mk {α β : PartialFun.{u}} (e : α ≃ β) : α ≅ β
   hom_inv_id' := (PFun.coe_comp _ _).symm.trans <| congr_arg coe e.symm_comp_self
   inv_hom_id' := (PFun.coe_comp _ _).symm.trans <| congr_arg coe e.self_comp_symm
 #align PartialFun.iso.mk PartialFun.Iso.mk
+-/
 
 end PartialFun
 
+#print typeToPartialFun /-
 /-- The forgetful functor from `Type` to `PartialFun` which forgets that the maps are total. -/
 def typeToPartialFun : Type u ⥤ PartialFun
     where
@@ -91,10 +100,12 @@ def typeToPartialFun : Type u ⥤ PartialFun
   map := @PFun.lift
   map_comp' _ _ _ _ _ := PFun.coe_comp _ _
 #align Type_to_PartialFun typeToPartialFun
+-/
 
 instance : Faithful typeToPartialFun :=
   ⟨fun X Y => PFun.lift_injective⟩
 
+#print pointedToPartialFun /-
 /-- The functor which deletes the point of a pointed type. In return, this makes the maps partial.
 This the computable part of the equivalence `PartialFun_equiv_Pointed`. -/
 @[simps map]
@@ -117,7 +128,9 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun
       rintro ⟨b, _, rfl : b = _, h⟩
       exact h
 #align Pointed_to_PartialFun pointedToPartialFun
+-/
 
+#print partialFunToPointed /-
 /-- The functor which maps undefined values to a new point. This makes the maps total and creates
 pointed types. This the noncomputable part of the equivalence `PartialFun_equiv_Pointed`. It can't
 be computable because `= option.none` is decidable while the domain of a general `part` isn't. -/
@@ -131,7 +144,9 @@ noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
       map_comp' := fun X Y Z f g =>
         Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.bind_toOption _ _ }
 #align PartialFun_to_Pointed partialFunToPointed
+-/
 
+#print partialFunEquivPointed /-
 /-- The equivalence induced by `PartialFun_to_Pointed` and `Pointed_to_PartialFun`.
 `part.equiv_option` made functorial. -/
 @[simps]
@@ -185,7 +200,9 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed := by
               · rfl
               · exact Eq.symm (of_not_not h))
 #align PartialFun_equiv_Pointed partialFunEquivPointed
+-/
 
+#print typeToPartialFunIsoPartialFunToPointed /-
 /-- Forgetting that maps are total and making them total again by adding a point is the same as just
 adding a point. -/
 @[simps]
@@ -201,4 +218,5 @@ noncomputable def typeToPartialFunIsoPartialFunToPointed :
     Pointed.Hom.ext _ _ <|
       funext fun a => Option.recOn a rfl fun a => by convert Part.some_toOption _
 #align Type_to_PartialFun_iso_PartialFun_to_Pointed typeToPartialFunIsoPartialFunToPointed
+-/
 
Diff
@@ -124,13 +124,12 @@ be computable because `= option.none` is decidable while the domain of a general
 @[simps map]
 noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
   classical exact
-      { obj := fun X => ⟨Option X, none⟩
-        map := fun X Y f => ⟨Option.elim' none fun a => (f a).toOption, rfl⟩
-        map_id' := fun X =>
-          Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.some_toOption _
-        map_comp' := fun X Y Z f g =>
-          Pointed.Hom.ext _ _ <|
-            funext fun o => Option.recOn o rfl fun a => Part.bind_toOption _ _ }
+    { obj := fun X => ⟨Option X, none⟩
+      map := fun X Y f => ⟨Option.elim' none fun a => (f a).toOption, rfl⟩
+      map_id' := fun X =>
+        Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.some_toOption _
+      map_comp' := fun X Y Z f g =>
+        Pointed.Hom.ext _ _ <| funext fun o => Option.recOn o rfl fun a => Part.bind_toOption _ _ }
 #align PartialFun_to_Pointed partialFunToPointed
 
 /-- The equivalence induced by `PartialFun_to_Pointed` and `Pointed_to_PartialFun`.
@@ -138,55 +137,53 @@ noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
 @[simps]
 noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed := by
   classical exact
-      equivalence.mk partialFunToPointed pointedToPartialFun
-        (nat_iso.of_components
-          (fun X =>
-            PartialFun.Iso.mk
-              { toFun := fun a => ⟨some a, some_ne_none a⟩
-                invFun := fun a => get <| ne_none_iff_is_some.1 a.2
-                left_inv := fun a => get_some _ _
-                right_inv := fun a => by
-                  simp only [Subtype.val_eq_coe, some_get, Subtype.coe_eta] })
-          fun X Y f =>
-          PFun.ext fun a b => by
-            unfold_projs
-            dsimp
-            rw [Part.bind_some]
-            refine' (part.mem_bind_iff.trans _).trans pfun.mem_to_subtype_iff.symm
-            obtain ⟨b | b, hb⟩ := b
-            · exact (hb rfl).elim
-            dsimp
-            simp_rw [Part.mem_some_iff, Subtype.mk_eq_mk, exists_prop, some_inj, exists_eq_right']
-            refine' part.mem_to_option.symm.trans _
-            exact eq_comm)
-        (nat_iso.of_components
-          (fun X =>
-            Pointed.Iso.mk
-              { toFun := Option.elim' X.point Subtype.val
-                invFun := fun a => if h : a = X.point then none else some ⟨_, h⟩
-                left_inv := fun a =>
-                  Option.recOn a (dif_pos rfl) fun a =>
-                    (dif_neg a.2).trans <| by
-                      simp only [Option.elim', Subtype.val_eq_coe, Subtype.coe_eta]
-                right_inv := fun a =>
-                  by
-                  change Option.elim' _ _ (dite _ _ _) = _
-                  split_ifs
-                  · rw [h]; rfl
-                  · rfl }
-              rfl)
-          fun X Y f =>
-          Pointed.Hom.ext _ _ <|
-            funext fun a =>
-              Option.recOn a f.map_point.symm fun a =>
-                by
-                unfold_projs
-                dsimp
-                change Option.elim' _ _ _ = _
-                rw [Part.elim_toOption]
+    equivalence.mk partialFunToPointed pointedToPartialFun
+      (nat_iso.of_components
+        (fun X =>
+          PartialFun.Iso.mk
+            { toFun := fun a => ⟨some a, some_ne_none a⟩
+              invFun := fun a => get <| ne_none_iff_is_some.1 a.2
+              left_inv := fun a => get_some _ _
+              right_inv := fun a => by simp only [Subtype.val_eq_coe, some_get, Subtype.coe_eta] })
+        fun X Y f =>
+        PFun.ext fun a b => by
+          unfold_projs
+          dsimp
+          rw [Part.bind_some]
+          refine' (part.mem_bind_iff.trans _).trans pfun.mem_to_subtype_iff.symm
+          obtain ⟨b | b, hb⟩ := b
+          · exact (hb rfl).elim
+          dsimp
+          simp_rw [Part.mem_some_iff, Subtype.mk_eq_mk, exists_prop, some_inj, exists_eq_right']
+          refine' part.mem_to_option.symm.trans _
+          exact eq_comm)
+      (nat_iso.of_components
+        (fun X =>
+          Pointed.Iso.mk
+            { toFun := Option.elim' X.point Subtype.val
+              invFun := fun a => if h : a = X.point then none else some ⟨_, h⟩
+              left_inv := fun a =>
+                Option.recOn a (dif_pos rfl) fun a =>
+                  (dif_neg a.2).trans <| by
+                    simp only [Option.elim', Subtype.val_eq_coe, Subtype.coe_eta]
+              right_inv := fun a => by
+                change Option.elim' _ _ (dite _ _ _) = _
                 split_ifs
-                · rfl
-                · exact Eq.symm (of_not_not h))
+                · rw [h]; rfl
+                · rfl }
+            rfl)
+        fun X Y f =>
+        Pointed.Hom.ext _ _ <|
+          funext fun a =>
+            Option.recOn a f.map_point.symm fun a =>
+              by
+              unfold_projs
+              dsimp
+              change Option.elim' _ _ _ = _
+              rw [Part.elim_toOption]
+              split_ifs
+              · rfl
+              · exact Eq.symm (of_not_not h))
 #align PartialFun_equiv_Pointed partialFunEquivPointed
 
 /-- Forgetting that maps are total and making them total again by adding a point is the same as just
Diff
@@ -172,8 +172,7 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed := by
                   by
                   change Option.elim' _ _ (dite _ _ _) = _
                   split_ifs
-                  · rw [h]
-                    rfl
+                  · rw [h]; rfl
                   · rfl }
               rfl)
           fun X Y f =>
Diff
@@ -103,12 +103,12 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun
   obj X := { x : X // x ≠ X.point }
   map X Y f := PFun.toSubtype _ f.toFun ∘ Subtype.val
   map_id' X :=
-    PFun.ext fun a b => PFun.mem_to_subtype_iff.trans (Subtype.coe_inj.trans Part.mem_some_iff.symm)
+    PFun.ext fun a b => PFun.mem_toSubtype_iff.trans (Subtype.coe_inj.trans Part.mem_some_iff.symm)
   map_comp' X Y Z f g :=
     PFun.ext fun a c =>
       by
       refine' (pfun.mem_to_subtype_iff.trans _).trans part.mem_bind_iff.symm
-      simp_rw [PFun.mem_to_subtype_iff, Subtype.exists]
+      simp_rw [PFun.mem_toSubtype_iff, Subtype.exists]
       refine'
         ⟨fun h =>
           ⟨f.to_fun a, fun ha =>

Changes in mathlib4

mathlib3
mathlib4
chore: classify porting notes referring to missing linters (#12098)

Reference the newly created issues #12094 and #12096, as well as the pre-existing #5171. Change all references to #10927 to #5171. Some of these changes were not labelled as "porting note"; change this for good measure.

Diff
@@ -45,7 +45,7 @@ namespace PartialFun
 instance : CoeSort PartialFun (Type*) :=
   ⟨id⟩
 
--- Porting note: removed `@[nolint has_nonempty_instance]`
+-- Porting note(#5171): removed `@[nolint has_nonempty_instance]`; linter not ported yet
 /-- Turns a type into a `PartialFun`. -/
 def of : Type* → PartialFun :=
   id
chore(CategoryTheory): move Full, Faithful, EssSurj, IsEquivalence and ReflectsIsomorphisms to the Functor namespace (#11985)

These notions on functors are now Functor.Full, Functor.Faithful, Functor.EssSurj, Functor.IsEquivalence, Functor.ReflectsIsomorphisms. Deprecated aliases are introduced for the previous names.

Diff
@@ -88,7 +88,7 @@ def typeToPartialFun : Type u ⥤ PartialFun where
   map_comp _ _ := PFun.coe_comp _ _
 #align Type_to_PartialFun typeToPartialFun
 
-instance : Faithful typeToPartialFun where
+instance : typeToPartialFun.Faithful where
   map_injective {_ _} := PFun.lift_injective
 
 /-- The functor which deletes the point of a pointed type. In return, this makes the maps partial.
doc: replace mathlib3 names in doc comments (#11952)

A few miscellaneous directories: RingTheory, SetTheory, Combinatorics and CategoryTheory.

Co-authored-by: Scott Morrison <scott@tqft.net>

Diff
@@ -112,7 +112,7 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun where
 
 /-- The functor which maps undefined values to a new point. This makes the maps total and creates
 pointed types. This is the noncomputable part of the equivalence `PartialFunEquivPointed`. It can't
-be computable because `= Option.none` is decidable while the domain of a general `part` isn't. -/
+be computable because `= Option.none` is decidable while the domain of a general `Part` isn't. -/
 @[simps obj map]
 noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
   classical
feat: Option {b // b ≠ a} ≃ α (#11095)

Extract from partialFunEquivPointed the equivalence between any type with a distinguished element and an Option type.

Co-authored-by: @YaelDillies <yael.dillies@gmail.com> Co-authored-by: @fpvandoorn <fpvdoorn@gmail.com>

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

Diff
@@ -28,7 +28,6 @@ constructive.
   (https://ncatlab.org/nlab/show/partial+function)
 -/
 
-
 open CategoryTheory Option
 
 universe u
@@ -94,7 +93,7 @@ instance : Faithful typeToPartialFun where
 
 /-- The functor which deletes the point of a pointed type. In return, this makes the maps partial.
 This is the computable part of the equivalence `PartialFunEquivPointed`. -/
-@[simps map]
+@[simps obj map]
 def pointedToPartialFun : Pointed.{u} ⥤ PartialFun where
   obj X := { x : X // x ≠ X.point }
   map f := PFun.toSubtype _ f.toFun ∘ Subtype.val
@@ -114,7 +113,7 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun where
 /-- The functor which maps undefined values to a new point. This makes the maps total and creates
 pointed types. This is the noncomputable part of the equivalence `PartialFunEquivPointed`. It can't
 be computable because `= Option.none` is decidable while the domain of a general `part` isn't. -/
-@[simps map]
+@[simps obj map]
 noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
   classical
   exact
@@ -157,35 +156,18 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed :=
             · intro h
               split_ifs at h with ha
               rw [some_inj] at h
-              exact ⟨b, ⟨ha, h.symm⟩, rfl⟩)
-    (NatIso.ofComponents (fun X => Pointed.Iso.mk
-      { toFun := Option.elim' X.point Subtype.val
-        invFun := fun a => by
-          classical
-          exact if h : a = X.point then none else some ⟨_, h⟩
-        left_inv := fun a => Option.recOn a (dif_pos rfl) fun a => by
-          dsimp
-          rw [dif_neg a.2]
-          rfl
-        right_inv := fun a => by
-          dsimp
-          split_ifs with h
-          · rw [h]
-            rfl
-          · rfl} rfl)
-      fun {X Y} f =>
-      Pointed.Hom.ext _ _ <|
-        funext fun a =>
-          Option.recOn a f.map_point.symm (by
-            rintro ⟨a, ha⟩
-            change Option.elim' _ _ _ = f.toFun a
-            dsimp
-            -- Porting note: `rw [Part.elim_toOption]` does not work because there are
-            -- conflicting `Decidable` instances
-            rw [Option.elim'_eq_elim, @Part.elim_toOption _ _ _ (Classical.propDecidable _)]
-            split_ifs with h
-            · rfl
-            · exact Eq.symm (of_not_not h)))
+              exact ⟨b, ⟨ha, h.symm⟩, rfl⟩) $
+    NatIso.ofComponents
+      (fun X ↦ Pointed.Iso.mk (by classical exact Equiv.optionSubtypeNe X.point) (by rfl))
+      fun {X Y} f ↦ Pointed.Hom.ext _ _ <| funext fun a ↦ by
+        obtain _ | ⟨a, ha⟩ := a
+        exact f.map_point.symm
+        classical
+        simp [Option.casesOn'_eq_elim, -Option.elim,
+          @Part.elim_toOption _ _ _ (Classical.propDecidable _), ha]
+        split_ifs with h
+        · simpa [eq_comm] using h
+        · simp
 #align PartialFun_equiv_Pointed partialFunEquivPointed
 
 /-- Forgetting that maps are total and making them total again by adding a point is the same as just
style: homogenise porting notes (#11145)

Homogenises porting notes via capitalisation and addition of whitespace.

It makes the following changes:

  • converts "--porting note" into "-- Porting note";
  • converts "porting note" into "Porting note".
Diff
@@ -46,13 +46,13 @@ namespace PartialFun
 instance : CoeSort PartialFun (Type*) :=
   ⟨id⟩
 
--- porting note: removed `@[nolint has_nonempty_instance]`
+-- Porting note: removed `@[nolint has_nonempty_instance]`
 /-- Turns a type into a `PartialFun`. -/
 def of : Type* → PartialFun :=
   id
 #align PartialFun.of PartialFun.of
 
--- porting note: removed this lemma which is useless because of the expansion of coercions
+-- Porting note: removed this lemma which is useless because of the expansion of coercions
 #noalign PartialFun.coe_of
 
 instance : Inhabited PartialFun :=
@@ -101,7 +101,7 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun where
   map_id X :=
     PFun.ext fun a b => PFun.mem_toSubtype_iff.trans (Subtype.coe_inj.trans Part.mem_some_iff.symm)
   map_comp f g := by
-    -- porting note: the proof was changed because the original mathlib3 proof no longer works
+    -- Porting note: the proof was changed because the original mathlib3 proof no longer works
     apply PFun.ext _
     rintro ⟨a, ha⟩ ⟨c, hc⟩
     constructor
@@ -142,7 +142,7 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed :=
         PFun.ext fun a b => by
           dsimp [PartialFun.Iso.mk, CategoryStruct.comp, pointedToPartialFun]
           rw [Part.bind_some]
-          -- porting note: the proof below has changed a lot because
+          -- Porting note: the proof below has changed a lot because
           -- `Part.mem_bind_iff` means that `b ∈ Part.bind f g` is equivalent
           -- to `∃ (a : α), a ∈ f ∧ b ∈ g a`, while in mathlib3 it was equivalent
           -- to `∃ (a : α) (H : a ∈ f), b ∈ g a`
@@ -180,7 +180,7 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed :=
             rintro ⟨a, ha⟩
             change Option.elim' _ _ _ = f.toFun a
             dsimp
-            -- porting note: `rw [Part.elim_toOption]` does not work because there are
+            -- Porting note: `rw [Part.elim_toOption]` does not work because there are
             -- conflicting `Decidable` instances
             rw [Option.elim'_eq_elim, @Part.elim_toOption _ _ _ (Classical.propDecidable _)]
             split_ifs with h
chore: remove terminal, terminal refines (#10762)

I replaced a few "terminal" refine/refine's with exact.

The strategy was very simple-minded: essentially any refine whose following line had smaller indentation got replaced by exact and then I cleaned up the mess.

This PR certainly leaves some further terminal refines, but maybe the current change is beneficial.

Diff
@@ -157,7 +157,7 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed :=
             · intro h
               split_ifs at h with ha
               rw [some_inj] at h
-              refine' ⟨b, ⟨ha, h.symm⟩, rfl⟩)
+              exact ⟨b, ⟨ha, h.symm⟩, rfl⟩)
     (NatIso.ofComponents (fun X => Pointed.Iso.mk
       { toFun := Option.elim' X.point Subtype.val
         invFun := fun a => by
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
@@ -33,22 +33,22 @@ open CategoryTheory Option
 
 universe u
 
-variable {α β : Type _}
+variable {α β : Type*}
 
 /-- The category of types equipped with partial functions. -/
 def PartialFun : Type _ :=
-  Type _
+  Type*
 set_option linter.uppercaseLean3 false
 #align PartialFun PartialFun
 
 namespace PartialFun
 
-instance : CoeSort PartialFun (Type _) :=
+instance : CoeSort PartialFun (Type*) :=
   ⟨id⟩
 
 -- porting note: removed `@[nolint has_nonempty_instance]`
 /-- Turns a type into a `PartialFun`. -/
-def of : Type _ → PartialFun :=
+def of : Type* → PartialFun :=
   id
 #align PartialFun.of PartialFun.of
 
@@ -56,7 +56,7 @@ def of : Type _ → PartialFun :=
 #noalign PartialFun.coe_of
 
 instance : Inhabited PartialFun :=
-  ⟨Type _⟩
+  ⟨Type*⟩
 
 instance largeCategory : LargeCategory.{u} PartialFun where
   Hom := PFun
chore: fix grammar mistakes (#6121)
Diff
@@ -93,7 +93,7 @@ instance : Faithful typeToPartialFun where
   map_injective {_ _} := PFun.lift_injective
 
 /-- The functor which deletes the point of a pointed type. In return, this makes the maps partial.
-This the computable part of the equivalence `PartialFunEquivPointed`. -/
+This is the computable part of the equivalence `PartialFunEquivPointed`. -/
 @[simps map]
 def pointedToPartialFun : Pointed.{u} ⥤ PartialFun where
   obj X := { x : X // x ≠ X.point }
@@ -112,7 +112,7 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun where
 #align Pointed_to_PartialFun pointedToPartialFun
 
 /-- The functor which maps undefined values to a new point. This makes the maps total and creates
-pointed types. This the noncomputable part of the equivalence `PartialFunEquivPointed`. It can't
+pointed types. This is the noncomputable part of the equivalence `PartialFunEquivPointed`. It can't
 be computable because `= Option.none` is decidable while the domain of a general `part` isn't. -/
 @[simps map]
 noncomputable def partialFunToPointed : PartialFun ⥤ Pointed := by
chore: script to replace headers with #align_import statements (#5979)

Open in Gitpod

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

Diff
@@ -2,15 +2,12 @@
 Copyright (c) 2022 Yaël Dillies. All rights reserved.
 Released under Apache 2.0 license as described in the file LICENSE.
 Authors: Yaël Dillies
-
-! This file was ported from Lean 3 source module category_theory.category.PartialFun
-! leanprover-community/mathlib commit 14b69e9f3c16630440a2cbd46f1ddad0d561dee7
-! Please do not edit these lines, except to modify the commit id
-! if you have ported upstream changes.
 -/
 import Mathlib.CategoryTheory.Category.Pointed
 import Mathlib.Data.PFun
 
+#align_import category_theory.category.PartialFun from "leanprover-community/mathlib"@"14b69e9f3c16630440a2cbd46f1ddad0d561dee7"
+
 /-!
 # The category of types with partial functions
 
chore: fix focusing dots (#5708)

This PR is the result of running

find . -type f -name "*.lean" -exec sed -i -E 's/^( +)\. /\1· /' {} \;
find . -type f -name "*.lean" -exec sed -i -E 'N;s/^( +·)\n +(.*)$/\1 \2/;P;D' {} \;

which firstly replaces . focusing dots with · and secondly removes isolated instances of such dots, unifying them with the following line. A new rule is placed in the style linter to verify this.

Diff
@@ -108,9 +108,9 @@ def pointedToPartialFun : Pointed.{u} ⥤ PartialFun where
     apply PFun.ext _
     rintro ⟨a, ha⟩ ⟨c, hc⟩
     constructor
-    . rintro ⟨h₁, h₂⟩
+    · rintro ⟨h₁, h₂⟩
       exact ⟨⟨fun h₀ => h₁ ((congr_arg g.toFun h₀).trans g.map_point), h₁⟩, h₂⟩
-    . rintro ⟨_, _, _⟩
+    · rintro ⟨_, _, _⟩
       exact ⟨_, rfl⟩
 #align Pointed_to_PartialFun pointedToPartialFun
 
@@ -152,12 +152,12 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed :=
           refine' (Part.mem_bind_iff.trans _).trans PFun.mem_toSubtype_iff.symm
           obtain ⟨b | b, hb⟩ := b
           · exact (hb rfl).elim
-          . dsimp [Part.toOption]
+          · dsimp [Part.toOption]
             simp_rw [Part.mem_some_iff, Subtype.mk_eq_mk]
             constructor
-            . rintro ⟨_, ⟨h₁, h₂⟩, h₃⟩
+            · rintro ⟨_, ⟨h₁, h₂⟩, h₃⟩
               rw [h₃, ← h₂, dif_pos h₁]
-            . intro h
+            · intro h
               split_ifs at h with ha
               rw [some_inj] at h
               refine' ⟨b, ⟨ha, h.symm⟩, rfl⟩)
@@ -173,9 +173,9 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed :=
         right_inv := fun a => by
           dsimp
           split_ifs with h
-          . rw [h]
+          · rw [h]
             rfl
-          . rfl} rfl)
+          · rfl} rfl)
       fun {X Y} f =>
       Pointed.Hom.ext _ _ <|
         funext fun a =>
@@ -187,8 +187,8 @@ noncomputable def partialFunEquivPointed : PartialFun.{u} ≌ Pointed :=
             -- conflicting `Decidable` instances
             rw [Option.elim'_eq_elim, @Part.elim_toOption _ _ _ (Classical.propDecidable _)]
             split_ifs with h
-            . rfl
-            . exact Eq.symm (of_not_not h)))
+            · rfl
+            · exact Eq.symm (of_not_not h)))
 #align PartialFun_equiv_Pointed partialFunEquivPointed
 
 /-- Forgetting that maps are total and making them total again by adding a point is the same as just
feat: port CategoryTheory.Category.PartialFun (#5301)

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

Dependencies 128

129 files ported (100.0%)
53217 lines ported (100.0%)

All dependencies are ported!