ghc-8.2.1.20171108: The GHC API

Safe HaskellNone
LanguageHaskell2010

HsLit

Synopsis

Documentation

data HsLit Source #

Haskell Literal

Constructors

HsChar SourceText Char

Character

HsCharPrim SourceText Char

Unboxed character

HsString SourceText FastString

String

HsStringPrim SourceText ByteString

Packed bytes

HsInt SourceText Integer

Genuinely an Int; arises from TcGenDeriv, and from TRANSLATION

HsIntPrim SourceText Integer

literal Int#

HsWordPrim SourceText Integer

literal Word#

HsInt64Prim SourceText Integer

literal Int64#

HsWord64Prim SourceText Integer

literal Word64#

HsInteger SourceText Integer Type

Genuinely an integer; arises only from TRANSLATION (overloaded literals are done with HsOverLit)

HsRat FractionalLit Type

Genuinely a rational; arises only from TRANSLATION (overloaded literals are done with HsOverLit)

HsFloatPrim FractionalLit

Unboxed Float

HsDoublePrim FractionalLit

Unboxed Double

Instances

Eq HsLit # 

Methods

(==) :: HsLit -> HsLit -> Bool #

(/=) :: HsLit -> HsLit -> Bool #

Data HsLit # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsLit -> c HsLit Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c HsLit Source #

toConstr :: HsLit -> Constr Source #

dataTypeOf :: HsLit -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c HsLit) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c HsLit) Source #

gmapT :: (forall b. Data b => b -> b) -> HsLit -> HsLit Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsLit -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsLit -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> HsLit -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsLit -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsLit -> m HsLit Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsLit -> m HsLit Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsLit -> m HsLit Source #

Outputable HsLit # 

data HsOverLit id Source #

Haskell Overloaded Literal

Constructors

OverLit 

Instances

Eq (HsOverLit id) # 

Methods

(==) :: HsOverLit id -> HsOverLit id -> Bool #

(/=) :: HsOverLit id -> HsOverLit id -> Bool #

DataId id => Data (HsOverLit id) # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> HsOverLit id -> c (HsOverLit id) Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c (HsOverLit id) Source #

toConstr :: HsOverLit id -> Constr Source #

dataTypeOf :: HsOverLit id -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c (HsOverLit id)) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c (HsOverLit id)) Source #

gmapT :: (forall b. Data b => b -> b) -> HsOverLit id -> HsOverLit id Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> HsOverLit id -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> HsOverLit id -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> HsOverLit id -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> HsOverLit id -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> HsOverLit id -> m (HsOverLit id) Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> HsOverLit id -> m (HsOverLit id) Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> HsOverLit id -> m (HsOverLit id) Source #

Ord (HsOverLit id) # 

Methods

compare :: HsOverLit id -> HsOverLit id -> Ordering #

(<) :: HsOverLit id -> HsOverLit id -> Bool #

(<=) :: HsOverLit id -> HsOverLit id -> Bool #

(>) :: HsOverLit id -> HsOverLit id -> Bool #

(>=) :: HsOverLit id -> HsOverLit id -> Bool #

max :: HsOverLit id -> HsOverLit id -> HsOverLit id #

min :: HsOverLit id -> HsOverLit id -> HsOverLit id #

OutputableBndrId id => Outputable (HsOverLit id) # 

data OverLitVal Source #

Overloaded Literal Value

Constructors

HsIntegral !SourceText !Integer

Integer-looking literals;

HsFractional !FractionalLit

Frac-looking literals

HsIsString !SourceText !FastString

String-looking literals

Instances

Eq OverLitVal # 
Data OverLitVal # 

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> OverLitVal -> c OverLitVal Source #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c OverLitVal Source #

toConstr :: OverLitVal -> Constr Source #

dataTypeOf :: OverLitVal -> DataType Source #

dataCast1 :: Typeable (* -> *) t => (forall d. Data d => c (t d)) -> Maybe (c OverLitVal) Source #

dataCast2 :: Typeable (* -> * -> *) t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c OverLitVal) Source #

gmapT :: (forall b. Data b => b -> b) -> OverLitVal -> OverLitVal Source #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> OverLitVal -> r Source #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> OverLitVal -> r Source #

gmapQ :: (forall d. Data d => d -> u) -> OverLitVal -> [u] Source #

gmapQi :: Int -> (forall d. Data d => d -> u) -> OverLitVal -> u Source #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> OverLitVal -> m OverLitVal Source #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> OverLitVal -> m OverLitVal Source #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> OverLitVal -> m OverLitVal Source #

Ord OverLitVal # 
Outputable OverLitVal # 

pmPprHsLit :: HsLit -> SDoc Source #

pmPprHsLit pretty prints literals and is used when pretty printing pattern match warnings. All are printed the same (i.e., without hashes if they are primitive and not wrapped in constructors if they are boxed). This happens mainly for too reasons: * We do not want to expose their internal representation * The warnings become too messy