hypertypes-0.2.2: Typed ASTs
Safe HaskellSafe-Inferred
LanguageHaskell2010

Hyper.Combinator.Compose

Description

Synopsis

Documentation

newtype HCompose a b h Source #

Compose two HyperTypes as an external and internal layer

Constructors

HCompose 

Fields

Instances

Instances details
(Infer m t, HPointed (InferOf t), HTraversable (InferOf t), HNodesConstraint t (HComposeConstraint1 (Infer m) Prune)) => Infer m (HCompose Prune t) Source # 
Instance details

Defined in Hyper.Type.Prune

(HNodes h0, HNodes h1, c (HCompose h0 h1), HNodesConstraint h0 (HComposeConstraint0 RNodes h1), HNodesConstraint h0 (HComposeConstraint0 (Recursively c) h1)) => Recursively c (HCompose h0 h1) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

recursively :: proxy (c (HCompose h0 h1)) -> Dict (c (HCompose h0 h1), HNodesConstraint (HCompose h0 h1) (Recursively c)) Source #

(Blame m t, HNodesConstraint t (HComposeConstraint1 (Infer m) Prune), HNodesConstraint t (HComposeConstraint1 (Blame m) Prune), HNodesConstraint t (HComposeConstraint1 RNodes Prune), HNodesConstraint t (HComposeConstraint1 (Recursively HFunctor) Prune), HNodesConstraint t (HComposeConstraint1 (Recursively HFoldable) Prune), HNodesConstraint t (HComposeConstraint1 RTraversable Prune)) => Blame m (HCompose Prune t) Source # 
Instance details

Defined in Hyper.Type.Prune

(HApply a, HApply b) => HApply (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

hzip :: forall (p :: HyperType) (q :: HyperType). (HCompose a b # p) -> (HCompose a b # q) -> HCompose a b # (p :*: q) Source #

(HFunctor c1, HContext c1, HFunctor h1, HContext h1) => HContext (HCompose c1 h1) Source # 
Instance details

Defined in Hyper.Class.Context

Methods

hcontext :: forall (p :: HyperType). (HCompose c1 h1 # p) -> HCompose c1 h1 # (HFunc p (Const (HCompose c1 h1 # p)) :*: p) Source #

(HFoldable a, HFoldable b) => HFoldable (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

hfoldMap :: Monoid a0 => (forall (n :: HyperType). HWitness (HCompose a b) n -> (p # n) -> a0) -> (HCompose a b # p) -> a0 Source #

(HFunctor a, HFunctor b) => HFunctor (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

hmap :: (forall (n :: HyperType). HWitness (HCompose a b) n -> (p # n) -> q # n) -> (HCompose a b # p) -> HCompose a b # q Source #

(HNodes a, HNodes b) => HNodes (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Associated Types

type HNodesConstraint (HCompose a b) c Source #

type HWitnessType (HCompose a b) :: HyperType -> Type Source #

Methods

hLiftConstraint :: forall c (n :: HyperType) r. HNodesConstraint (HCompose a b) c => HWitness (HCompose a b) n -> Proxy c -> (c n => r) -> r Source #

(HPointed a, HPointed b) => HPointed (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

hpure :: (forall (n :: HyperType). HWitness (HCompose a b) n -> p # n) -> HCompose a b # p Source #

(HNodes a, HNodes b, HNodesConstraint a (HComposeConstraint0 RNodes b)) => RNodes (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

(HTraversable a, HTraversable b, HNodesConstraint a (HComposeConstraint0 RNodes b), HNodesConstraint a (HComposeConstraint0 (Recursively HFunctor) b), HNodesConstraint a (HComposeConstraint0 (Recursively HFoldable) b), HNodesConstraint a (HComposeConstraint0 RTraversable b)) => RTraversable (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

(HTraversable a, HTraversable b) => HTraversable (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

hsequence :: forall f (p :: AHyperType -> Type). Applicative f => (HCompose a b # ContainedH f p) -> f (HCompose a b # p) Source #

(ZipMatch h0, ZipMatch h1, HTraversable h0, HFunctor h1) => ZipMatch (HCompose h0 h1) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

zipMatch :: forall (p :: HyperType) (q :: HyperType). (HCompose h0 h1 # p) -> (HCompose h0 h1 # q) -> Maybe (HCompose h0 h1 # (p :*: q)) Source #

Generic (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Associated Types

type Rep (HCompose a b h) :: Type -> Type #

Methods

from :: HCompose a b h -> Rep (HCompose a b h) x #

to :: Rep (HCompose a b h) x -> HCompose a b h #

Constraints (HCompose a b h) Show => Show (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

showsPrec :: Int -> HCompose a b h -> ShowS #

show :: HCompose a b h -> String #

showList :: [HCompose a b h] -> ShowS #

Constraints (HCompose a b h) Binary => Binary (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

put :: HCompose a b h -> Put #

get :: Get (HCompose a b h) #

putList :: [HCompose a b h] -> Put #

Constraints (HCompose a b h) NFData => NFData (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

rnf :: HCompose a b h -> () #

Constraints (HCompose a b h) Eq => Eq (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

(==) :: HCompose a b h -> HCompose a b h -> Bool #

(/=) :: HCompose a b h -> HCompose a b h -> Bool #

Constraints (HCompose a b h) Ord => Ord (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

compare :: HCompose a b h -> HCompose a b h -> Ordering #

(<) :: HCompose a b h -> HCompose a b h -> Bool #

(<=) :: HCompose a b h -> HCompose a b h -> Bool #

(>) :: HCompose a b h -> HCompose a b h -> Bool #

(>=) :: HCompose a b h -> HCompose a b h -> Bool #

max :: HCompose a b h -> HCompose a b h -> HCompose a b h #

min :: HCompose a b h -> HCompose a b h -> HCompose a b h #

Pretty (a # HCompose b (GetHyperType h)) => Pretty (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

pPrintPrec :: PrettyLevel -> Rational -> HCompose a b h -> Doc #

pPrint :: HCompose a b h -> Doc #

pPrintList :: PrettyLevel -> [HCompose a b h] -> Doc #

type InferOf (HCompose Prune t) Source # 
Instance details

Defined in Hyper.Type.Prune

type HWitnessType (HCompose a b) Source # 
Instance details

Defined in Hyper.Combinator.Compose

type HNodesConstraint (HCompose a b) c Source # 
Instance details

Defined in Hyper.Combinator.Compose

type Rep (HCompose a b h) Source # 
Instance details

Defined in Hyper.Combinator.Compose

type Rep (HCompose a b h) = D1 ('MetaData "HCompose" "Hyper.Combinator.Compose" "hypertypes-0.2.2-9g9pX7Hb2mGI4yyssTDpOd" 'True) (C1 ('MetaCons "HCompose" 'PrefixI 'True) (S1 ('MetaSel ('Just "getHCompose") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (a # HCompose b (GetHyperType h)))))

_HCompose :: Iso (HCompose a0 b0 # h0) (HCompose a1 b1 # h1) (a0 # HCompose b0 h0) (a1 # HCompose b1 h1) Source #

An Iso for the HCompose newtype

data W_HCompose a b n where Source #

Constructors

W_HCompose :: HWitness a a0 -> HWitness b b0 -> W_HCompose a b (HCompose a0 b0) 

class HComposeConstraint1 (c :: HyperType -> Constraint) (h0 :: HyperType) (h1 :: HyperType) Source #

Minimal complete definition

hComposeConstraint1

Instances

Instances details
c (HCompose h0 h1) => HComposeConstraint1 c h0 h1 Source # 
Instance details

Defined in Hyper.Combinator.Compose

Methods

hComposeConstraint1 :: Dict (c (HCompose h0 h1))

decompose :: forall a0 b0 a1 b1. (Recursively HFunctor a0, Recursively HFunctor b0, Recursively HFunctor a1, Recursively HFunctor b1) => Iso (Pure # HCompose a0 b0) (Pure # HCompose a1 b1) (a0 # b0) (a1 # b1) Source #

Inject Pure between two hypertypes.

hcomposed :: (Profunctor p, Functor f) => Optic p f (a0 # HCompose b0 c0) (a1 # HCompose b1 c1) (HCompose a2 b2 # c2) (HCompose a3 b3 # c3) -> Optic p f (HCompose a0 b0 # c0) (HCompose a1 b1 # c1) (a2 # HCompose b2 c2) (a3 # HCompose b3 c3) Source #