Package0.1.0.0Data
either-n
Data types like Either but with more constructors
- Version0.1.0.0
- CategoryData
- LicenceBSD-3-Clause
- AuthorTony Morris <ʇǝu˙sıɹɹoɯʇ@ןןǝʞsɐɥ> <dibblego>
- MaintainerTony Morris <ʇǝu˙sıɹɹoɯʇ@ןןǝʞsɐɥ> <dibblego>
- Homepagegitlab.com/tonymorris/either-n
- Pinned byhackage either-n 0.1.0.0
- Sourcehackage.haskell.org/package/either-n-0.1.0.0
Modules
25 modules- Data.Either30Data types similar to Data.Either with three constructors.
- Data.Either3.Either311A data type similar to Data.Either with three constructors.
- Data.Either3.Either3T15Either3 inside a type constructor f, in the same way that ExceptT e m a is m (Either e a). Use _Wrapped to convert between Either3T f a b…
- Data.Lens.Injection0Injections into sum types, as prisms. The sum-type duals of the FieldN classes in Control.Lens.Tuple.
- Data.Lens.Injection.Generic2A prism to the nth constructor of any type with a Generic instance. This is the default implementation of each of the InjectionN classes.
- Data.Lens.Injection.Injection11The first injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field1.
- Data.Lens.Injection.Injection101The tenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field10.
- Data.Lens.Injection.Injection111The eleventh injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field11.
- Data.Lens.Injection.Injection121The twelfth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field12.
- Data.Lens.Injection.Injection131The thirteenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field13.
- Data.Lens.Injection.Injection141The fourteenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field14.
- Data.Lens.Injection.Injection151The fifteenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field15.
- Data.Lens.Injection.Injection161The sixteenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field16.
- Data.Lens.Injection.Injection171The seventeenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field17.
- Data.Lens.Injection.Injection181The eighteenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field18.
- Data.Lens.Injection.Injection191The nineteenth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field19.
- Data.Lens.Injection.Injection21The second injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field2.
- Data.Lens.Injection.Injection31The third injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field3.
- Data.Lens.Injection.Injection41The fourth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field4.
- Data.Lens.Injection.Injection51The fifth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field5.
- Data.Lens.Injection.Injection61The sixth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field6.
- Data.Lens.Injection.Injection71The seventh injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field7.
- Data.Lens.Injection.Injection81The eighth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field8.
- Data.Lens.Injection.Injection91The ninth injection of a sum type, as a prism. The sum-type dual of Control.Lens.Field9.
Internal modules · 1
- Data.Lens.Injection.Generic.Internal6The generic machinery behind injection. This module is internal: its contents may change in any release, without a
Description
Data types like Either but with more constructors, and optics for the constructors of any sum type.
Either3 a b c is a value of one of three types, with the constructors First3, Second3 and Third3. The Functor, Applicative and Monad instances act on the third type parameter, so First3 and Second3 short-circuit, in the same way Left does for Either.
Either3T f a b c is an Either3 inside a type constructor f, in the same way that ExceptT e m a is m (Either e a). Use _Wrapped to convert between Either3T f a b c and f (Either3 a b c). The mtl classes are lifted from f.
Data.Lens.Injection provides the classes Injection1 to Injection19, the sum-type duals of Field1 to Field19 from lens. Where _1 is a lens to the first field of a product, _I1 is a prism to the first constructor of a sum. Each class has a default implementation for any type with a Generic instance.
Depends on
7 packages- assoc-1.1.1in this set
- base-4.23.0.0with GHC
- deepseq-1.5.2.0with GHC
- lens-5.3.6in this set
- mtl-2.3.2with GHC
- selective-0.7.0.1in this set
- semigroupoids-6.0.2in this set