vinyl-0.8.1.1: Extensible Records

Safe HaskellNone
LanguageHaskell2010

Data.Vinyl

Synopsis

Documentation

data ARec (f :: k -> *) (ts :: [k]) Source #

An array-backed extensible record with constant-time field access.

Instances
(i ~ RIndex t ts, NatToInt (RIndex t ts)) => RecElem (ARec :: (k -> *) -> [k] -> *) (t :: k) (ts :: [k]) i Source # 
Instance details

Defined in Data.Vinyl.ARec

Methods

rlens :: Functor g => sing t -> (f t -> g (f t)) -> ARec f ts -> g (ARec f ts) Source #

rget :: sing t -> ARec f ts -> f t Source #

rput :: f t -> ARec f ts -> ARec f ts Source #

(is ~ RImage rs ss, IndexWitnesses is, NatToInt (RLength rs)) => RecSubset (ARec :: (k -> *) -> [k] -> *) (rs :: [k]) (ss :: [k]) is Source # 
Instance details

Defined in Data.Vinyl.ARec

Methods

rsubset :: Functor g => (ARec f rs -> g (ARec f rs)) -> ARec f ss -> g (ARec f ss) Source #

rcast :: ARec f ss -> ARec f rs Source #

rreplace :: ARec f rs -> ARec f ss -> ARec f ss Source #

(AllConstrained (IndexableField rs) rs, RecApplicative rs, Eq (Rec f rs)) => Eq (ARec f rs) Source # 
Instance details

Defined in Data.Vinyl.ARec

Methods

(==) :: ARec f rs -> ARec f rs -> Bool #

(/=) :: ARec f rs -> ARec f rs -> Bool #

(AllConstrained (IndexableField rs) rs, RecApplicative rs, Ord (Rec f rs)) => Ord (ARec f rs) Source # 
Instance details

Defined in Data.Vinyl.ARec

Methods

compare :: ARec f rs -> ARec f rs -> Ordering #

(<) :: ARec f rs -> ARec f rs -> Bool #

(<=) :: ARec f rs -> ARec f rs -> Bool #

(>) :: ARec f rs -> ARec f rs -> Bool #

(>=) :: ARec f rs -> ARec f rs -> Bool #

max :: ARec f rs -> ARec f rs -> ARec f rs #

min :: ARec f rs -> ARec f rs -> ARec f rs #

(AllConstrained (IndexableField rs) rs, RecApplicative rs, Show (Rec f rs)) => Show (ARec f rs) Source # 
Instance details

Defined in Data.Vinyl.ARec

Methods

showsPrec :: Int -> ARec f rs -> ShowS #

show :: ARec f rs -> String #

showList :: [ARec f rs] -> ShowS #

toARec :: forall f ts. NatToInt (RLength ts) => Rec f ts -> ARec f ts Source #

Convert a Rec into an ARec for constant-time field access.

fromARec :: forall f ts. (RecApplicative ts, AllConstrained (IndexableField ts) ts) => ARec f ts -> Rec f ts Source #

Convert an ARec into a Rec.