imperative-edsl-0.8.2: Deep embedding of imperative programs with code generation
Safe HaskellNone
LanguageHaskell2010

Language.Embedded.Imperative.Args

Description

Various types of function arguments

Synopsis

Documentation

data RefArg pred where Source #

Reference argument

Constructors

RefArg :: pred a => Ref a -> RefArg pred 

Instances

Instances details
CompTypeClass ct => Arg RefArg (ct :: Type -> Constraint) Source # 
Instance details

Defined in Language.Embedded.Imperative.Args

data ArrArg pred where Source #

Mutable array argument

Constructors

ArrArg :: pred a => Arr i a -> ArrArg pred 

Instances

Instances details
CompTypeClass ct => Arg ArrArg (ct :: Type -> Constraint) Source # 
Instance details

Defined in Language.Embedded.Imperative.Args

data IArrArg pred where Source #

Immutable array argument

Constructors

IArrArg :: pred a => IArr i a -> IArrArg pred 

Instances

Instances details
CompTypeClass ct => Arg IArrArg (ct :: Type -> Constraint) Source # 
Instance details

Defined in Language.Embedded.Imperative.Args

data PtrArg pred where Source #

Pointer argument

Constructors

PtrArg :: pred a => Ptr a -> PtrArg pred 

Instances

Instances details
CompTypeClass ct => Arg PtrArg (ct :: Type -> Constraint) Source # 
Instance details

Defined in Language.Embedded.Imperative.Args

data ObjArg pred where Source #

Abstract object argument

Constructors

ObjArg :: Object -> ObjArg pred 

Instances

Instances details
Arg (ObjArg :: k -> Type) (pred :: k) Source # 
Instance details

Defined in Language.Embedded.Imperative.Args

Methods

mkArg :: ObjArg pred -> CGen Exp Source #

mkParam :: ObjArg pred -> CGen Param Source #

data StrArg pred where Source #

Constant string argument

Constructors

StrArg :: String -> StrArg pred 

Instances

Instances details
Arg (StrArg :: k -> Type) (pred :: k) Source # 
Instance details

Defined in Language.Embedded.Imperative.Args

Methods

mkArg :: StrArg pred -> CGen Exp Source #

mkParam :: StrArg pred -> CGen Param Source #

data ConstArg pred where Source #

Constructors

ConstArg 

Fields

Instances

Instances details
Arg (ConstArg :: k -> Type) (pred :: k) Source # 
Instance details

Defined in Language.Embedded.Imperative.Args

Methods

mkArg :: ConstArg pred -> CGen Exp Source #

mkParam :: ConstArg pred -> CGen Param Source #