generic-override-0.2.0.0: Provides functionality for overriding instances for generic derivation
Safe HaskellNone
LanguageHaskell2010

Data.Override

Description

The public, stable generic-override API.

Synopsis

Documentation

newtype Override a (xs :: [*]) Source #

The feature of this library. For use with DerivingVia. Apply it to a type a and supply a type-level list of instance overrides xs.

Constructors

Override a 

Instances

Instances details
(Generic (Override a xs), Eq (Rep (Override a xs) ())) => Eq (Override a xs) Source # 
Instance details

Defined in Data.Override.Instances

Methods

(==) :: Override a xs -> Override a xs -> Bool #

(/=) :: Override a xs -> Override a xs -> Bool #

(Generic (Override a xs), Ord (Rep (Override a xs) ())) => Ord (Override a xs) Source # 
Instance details

Defined in Data.Override.Instances

Methods

compare :: Override a xs -> Override a xs -> Ordering #

(<) :: Override a xs -> Override a xs -> Bool #

(<=) :: Override a xs -> Override a xs -> Bool #

(>) :: Override a xs -> Override a xs -> Bool #

(>=) :: Override a xs -> Override a xs -> Bool #

max :: Override a xs -> Override a xs -> Override a xs #

min :: Override a xs -> Override a xs -> Override a xs #

(Generic a, GOverride xs (Rep a)) => Generic (Override a xs) Source # 
Instance details

Defined in Data.Override.Internal

Associated Types

type Rep (Override a xs) :: Type -> Type #

Methods

from :: Override a xs -> Rep (Override a xs) x #

to :: Rep (Override a xs) x -> Override a xs #

(Generic (Override a xs), Semigroup (Rep (Override a xs) ())) => Semigroup (Override a xs) Source # 
Instance details

Defined in Data.Override.Instances

Methods

(<>) :: Override a xs -> Override a xs -> Override a xs #

sconcat :: NonEmpty (Override a xs) -> Override a xs #

stimes :: Integral b => b -> Override a xs -> Override a xs #

(Generic (Override a xs), Monoid (Rep (Override a xs) ())) => Monoid (Override a xs) Source # 
Instance details

Defined in Data.Override.Instances

Methods

mempty :: Override a xs #

mappend :: Override a xs -> Override a xs -> Override a xs #

mconcat :: [Override a xs] -> Override a xs #

type Rep (Override a xs) Source # 
Instance details

Defined in Data.Override.Internal

type Rep (Override a xs) = OverrideRep xs (Rep a)

data As (o :: k) n Source #

Used to construct a type-level override. Usually used infix. The o should be either a type (kind *) or a type-level string (kind Symbol).

data With (o :: k) (w :: * -> *) Source #

Used to wrap a field into a something of kind * -> *, for example another newtype.