Package2.2.2.0GenericsRecordsLens
generic-lens
Generically derive traversals, lenses and prisms.
- Version2.2.2.0
- CategoryGenerics, Records, Lens
- LicenceBSD-3-Clause
- AuthorCsongor Kiss
- Maintainerkiss.csongor.kiss@gmail.com
- Homepagegithub.com/kcsongor/generic-lens
- Pinned byhackage generic-lens 2.2.2.0
- Sourcehackage.haskell.org/package/generic-lens-2.2.2.0
Modules
20 modules- Data.Generics.Labels4Provides an (orphan) IsLabel instance for field lenses and constructor prisms.
- Data.Generics.Product0Magic product operations using Generics These classes need not be instantiated manually, as GHC can automatically
- Data.Generics.Product.Any1Derive a variety of lenses generically.
- Data.Generics.Product.Fields5Derive record field getters and setters generically.
- Data.Generics.Product.HList1Derive an isomorphism between a product type and a flat HList.
- Data.Generics.Product.Param5Derive traversals over type parameters
- Data.Generics.Product.Positions6Derive positional product type getters and setters generically.
- Data.Generics.Product.Subtype1Structural subtype relationships between product types.
- Data.Generics.Product.Typed1Derive lenses of a given type in a product.
- Data.Generics.Product.Types7Derive traversals of a given type in a product.
- Data.Generics.Sum0Magic sum operations using Generics These classes need not be instantiated manually, as GHC can automatically
- Data.Generics.Sum.Any1Derive a variety of prisms generically.
- Data.Generics.Sum.Constructors4Derive constructor-name-based prisms generically.
- Data.Generics.Sum.Subtype1Structural subtype relationships between sum types.
- Data.Generics.Sum.Typed1Derive constructor-field-type-based prisms generically.
- Data.Generics.Wrapped5Derive an isomorphism between a newtype and its wrapped type.
Internal modules · 4
- Data.Generics.Internal.VL11
- Data.Generics.Internal.VL.Iso14Internal lens helpers. Only exported for Haddock
- Data.Generics.Internal.VL.Lens10Internal lens helpers. Only exported for Haddock
- Data.Generics.Internal.VL.Prism7Internal lens helpers. Only exported for Haddock
Description
This library uses GHC.Generics to derive efficient optics (traversals, lenses and prisms) for algebraic data types in a type-directed way, with a focus on good type inference and error messages when possible.
The library exposes a van Laarhoven interface. For an alternative interface, supporting an opaque optic type, see generic-optics.
Depends on
4 packages- base-4.20.2.0with GHC
- generic-lens-core-2.2.1.0in this set
- profunctors-5.6.3in this set
- text-2.1.3with GHC