Bundled types #
Bundled c
provides a uniform structure for bundling a type equipped with a type class.
We provide Category
instances for these in
Mathlib/CategoryTheory/ConcreteCategory/UnbundledHom.lean
(for categories with unbundled homs, e.g. topological spaces)
and in Mathlib/CategoryTheory/ConcreteCategory/BundledHom.lean
(for categories with bundled homs, e.g. monoids).
A generic function for lifting a type equipped with an instance to a bundled object.
Equations
- CategoryTheory.Bundled.of α = { α := α, str := str }
Instances For
instance
CategoryTheory.Bundled.coeSort
{c : Type u → Type v}
:
CoeSort (CategoryTheory.Bundled c) (Type u)
Equations
- CategoryTheory.Bundled.coeSort = { coe := CategoryTheory.Bundled.α }
def
CategoryTheory.Bundled.map
{c : Type u → Type v}
{d : Type u → Type v}
(f : {α : Type u} → c α → d α)
(b : CategoryTheory.Bundled c)
:
Map over the bundled structure
Equations
- CategoryTheory.Bundled.map f b = { α := ↑b, str := f b.str }