Safe Haskell | Safe |
---|---|
Language | Haskell98 |
Synopsis
- data Prim
- = PrimTagUnit
- | PrimTagList
- | PrimLitBool Bool
- | PrimLitNat Integer
- | PrimLitInt Integer
- | PrimLitWord8 Word8
- | PrimLitWord16 Word16
- | PrimLitWord32 Word32
- | PrimLitWord64 Word64
- | PrimLitInt8 Int8
- | PrimLitInt16 Int16
- | PrimLitInt32 Int32
- | PrimLitInt64 Int64
- | PrimLitFloat32 Float
- | PrimLitFloat64 Double
- | PrimOp Text
- pprPrim :: Prim -> Text
- readPrim :: Set Text -> Text -> Maybe Prim
- makeXBool :: Bool -> Exp s Prim
- takeXBool :: Exp s Prim -> Maybe Bool
- takeArgBool :: [Exp s Prim] -> Maybe (Bool, [Exp s Prim])
- makeXNat :: Integer -> Exp s Prim
- takeXNat :: Exp s Prim -> Maybe Integer
- takeArgNat :: [Exp s Prim] -> Maybe (Integer, [Exp s Prim])
- makeXList :: [Exp s Prim] -> Exp s Prim
Documentation
Primitive values and operators.
Pretty
Bool
takeArgBool :: [Exp s Prim] -> Maybe (Bool, [Exp s Prim]) Source #
Split a literal Bool from an argument list.
Nat
takeArgNat :: [Exp s Prim] -> Maybe (Integer, [Exp s Prim]) Source #
Split a literal Nat from an argument list.