Package2.3.0.0GenericsRecordsLens
generic-lens
Generically derive traversals, lenses and prisms.
- Version2.3.0.0
- CategoryGenerics, Records, Lens
- LicenceBSD-3-Clause
- AuthorCsongor Kiss
- Maintainerkiss.csongor.kiss@gmail.com
- Homepagegithub.com/kcsongor/generic-lens
- Pinned byhackage generic-lens 2.3.0.0
- Sourcehackage.haskell.org/package/generic-lens-2.3.0.0
Modules
- Data.Generics.LabelsProvides an (orphan) IsLabel instance for field lenses and constructor
- Data.Generics.ProductMagic product operations using Generics These classes need not be instantiated manually, as GHC can automatically
- Data.Generics.Product.AnyDerive a variety of lenses generically.
- Data.Generics.Product.FieldsDerive record field getters and setters generically.
- Data.Generics.Product.HListDerive an isomorphism between a product type and a flat HList.
- Data.Generics.Product.ParamDerive traversals over type parameters
- Data.Generics.Product.PositionsDerive positional product type getters and setters generically.
- Data.Generics.Product.SubtypeStructural subtype relationships between product types.
- Data.Generics.Product.TypedDerive lenses of a given type in a product.
- Data.Generics.Product.TypesDerive traversals of a given type in a product.
- Data.Generics.SumMagic sum operations using Generics These classes need not be instantiated manually, as GHC can automatically
- Data.Generics.Sum.AnyDerive a variety of prisms generically.
- Data.Generics.Sum.ConstructorsDerive constructor-name-based prisms generically.
- Data.Generics.Sum.SubtypeStructural subtype relationships between sum types.
- Data.Generics.Sum.TypedDerive constructor-field-type-based prisms generically.
- Data.Generics.WrappedDerive an isomorphism between a newtype and its wrapped type.
Internal modules · 4
- Data.Generics.Internal.VL
- Data.Generics.Internal.VL.IsoInternal lens helpers. Only exported for Haddock
- Data.Generics.Internal.VL.LensInternal lens helpers. Only exported for Haddock
- Data.Generics.Internal.VL.PrismInternal 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
3 packages- base-4.23.0.0with GHC
- generic-lens-core-2.3.0.0in this set
- profunctors-5.6.3in this set