envparse-0.6.0: Parse environment variables
Safe HaskellSafe-Inferred
LanguageHaskell2010

Env.Internal.Free

Contents

Description

Alt F is the free Alternative functor on F

Synopsis

Documentation

data Alt (f :: Type -> Type) a where Source #

Constructors

Nope :: forall (f :: Type -> Type) a. Alt f a 
Pure :: forall a (f :: Type -> Type). a -> Alt f a 
Ap :: forall (f :: Type -> Type) a1 a. Alt f (a1 -> a) -> Alt f a1 -> Alt f a 
Alt :: forall (f :: Type -> Type) a. Alt f a -> Alt f a -> Alt f a 
Lift :: forall (f :: Type -> Type) a. f a -> Alt f a 

Instances

Instances details
Functor f => Alternative (Alt f) Source # 
Instance details

Defined in Env.Internal.Free

Methods

empty :: Alt f a #

(<|>) :: Alt f a -> Alt f a -> Alt f a #

some :: Alt f a -> Alt f [a] #

many :: Alt f a -> Alt f [a] #

Functor f => Applicative (Alt f) Source # 
Instance details

Defined in Env.Internal.Free

Methods

pure :: a -> Alt f a #

(<*>) :: Alt f (a -> b) -> Alt f a -> Alt f b #

liftA2 :: (a -> b -> c) -> Alt f a -> Alt f b -> Alt f c #

(*>) :: Alt f a -> Alt f b -> Alt f b #

(<*) :: Alt f a -> Alt f b -> Alt f a #

Functor f => Functor (Alt f) Source # 
Instance details

Defined in Env.Internal.Free

Methods

fmap :: (a -> b) -> Alt f a -> Alt f b #

(<$) :: a -> Alt f b -> Alt f a #

liftAlt :: f a -> Alt f a Source #

runAlt :: forall f g a. Alternative g => (forall x. f x -> g x) -> Alt f a -> g a Source #

foldAlt :: Monoid p => (forall a. f a -> p) -> Alt f b -> p Source #

hoistAlt :: forall f g b. Functor g => (forall a. f a -> g a) -> Alt f b -> Alt g b Source #

Debug

inspect :: forall (f :: Type -> Type) a. Alt f a -> String Source #

Print the free structure