sslang-0.1.0.0
Safe HaskellNone
LanguageHaskell2010

Codegen.Typegen

Description

Extract and encapsulate the type information needed during codegen.

Synopsis

Documentation

data DConInfo Source #

Information and codegen handlers associated with each data constructor.

Constructors

DConInfo 

Fields

data TConInfo Source #

Information and codegen handlers associated with each type constructor.

Constructors

TConInfo 

Fields

  • typeEncoding :: TypeEncoding

    how the data type is encoded

  • typeScrut :: Exp -> Exp

    how to retrieve the tag of an instance

data TypegenInfo Source #

Type-related information, abstracted behind partial lookup functions.

Constructors

TypegenInfo 

Fields

genTypes :: [(TConId, TypeDef)] -> Pass ([Definition], TypegenInfo) Source #

Create codegen definitions and helpers for sslang type definitions.