| ghc-6.12.3: The GHC API | Contents | Index

HsLit

Contents

Before* type checking, the SyntaxExpr in an HsOverLit is the
After* type checking, it is a witness for the literal, such as

Synopsis

data HsLit

= HsChar Char
| HsCharPrim Char
| HsString FastString
| HsStringPrim FastString
| HsInt Integer
| HsIntPrim Integer
| HsWordPrim Integer
| HsInteger Integer Type
| HsRat Rational Type
| HsFloatPrim Rational
| HsDoublePrim Rational

data HsOverLit id = OverLit {

ol_val :: OverLitVal
ol_rebindable :: Bool
ol_witness :: SyntaxExpr id
ol_type :: PostTcType

}

data OverLitVal

= HsIntegral !Integer
| HsFractional !Rational
| HsIsString !FastString

overLitType :: HsOverLit a -> Type

Documentation
data HsLit

Constructors

HsChar Char |
HsCharPrim Char |
HsString FastString |
HsStringPrim FastString |
HsInt Integer |
HsIntPrim Integer |
HsWordPrim Integer |
HsInteger Integer Type |
HsRat Rational Type |
HsFloatPrim Rational |
HsDoublePrim Rational |

Instances

Eq HsLit
Outputable HsLit

data HsOverLit id

Constructors

OverLit |

ol_val :: OverLitVal |
ol_rebindable :: Bool |
ol_witness :: SyntaxExpr id |
ol_type :: PostTcType |

Instances

Eq (HsOverLit id)
Ord (HsOverLit id)
OutputableBndr id => Outputable (HsOverLit id)

data OverLitVal

Constructors

HsIntegral !Integer |
HsFractional !Rational |
HsIsString !FastString |

Instances

Eq OverLitVal
Ord OverLitVal
Outputable OverLitVal

overLitType :: HsOverLit a -> Type
Before* type checking, the SyntaxExpr in an HsOverLit is the
After* type checking, it is a witness for the literal, such as
Produced by Haddock version 2.6.1