| Safe Haskell | Safe |
|---|---|
| Language | Haskell98 |
DDC.Source.Tetra.DataDef
Description
Source Tetra data type definitions.
- data DataDef n = DataDef {
- dataDefTypeName :: !n
- dataDefParams :: [Bind n]
- dataDefCtors :: [DataCtor n]
- typeEnvOfDataDef :: Ord n => DataDef n -> TypeEnv n
- data DataCtor n = DataCtor {
- dataCtorName :: !n
- dataCtorFieldTypes :: ![Type n]
- dataCtorResultType :: !(Type n)
- typeOfDataCtor :: DataDef n -> DataCtor n -> Type n
Data Type Definition.
Data type definitions.
Constructors
| DataDef | |
Fields
| |
typeEnvOfDataDef :: Ord n => DataDef n -> TypeEnv n Source
Take the types of data constructors from a data type definition.
Data Constructor Definition.
A data type constructor definition.
Constructors
| DataCtor | |
Fields
| |
typeOfDataCtor :: DataDef n -> DataCtor n -> Type n Source
Get the type of a data constructor.