ghc-9.6.3: The GHC API

Safe Haskell | Safe-Inferred
Language | Haskell2010

GHC.StgToJS.Literal

Synopsis

- genLit :: HasDebugCallStack => Literal -> G [JExpr]
- genStaticLit :: Literal -> G [StaticLit]

# Documentation

genLit :: HasDebugCallStack => Literal -> G [JExpr] Source #

Generate JS expressions for a Literal

Literals represented with 2 values: * Addr# (Null and Strings): array and offset * 64-bit values: high 32-bit, low 32-bit * labels: call to h$mkFunctionPtr and 0, or function name and 0

genStaticLit :: Literal -> G [StaticLit] Source #

generate a literal for the static init tables