Copyright | (c) 2011 National Institute of Aerospace / Galois Inc. |
---|---|
Safe Haskell | Safe |
Language | Haskell2010 |
Copilot.Core.Expr
Description
Synopsis
- type Id = Int
- type Name = String
- data Expr a where
- Const :: forall a. Typeable a => Type a -> a -> Expr a
- Drop :: forall a. Typeable a => Type a -> DropIdx -> Id -> Expr a
- Local :: forall a1 a. Typeable a1 => Type a1 -> Type a -> Name -> Expr a1 -> Expr a -> Expr a
- Var :: forall a. Typeable a => Type a -> Name -> Expr a
- ExternVar :: forall a. Typeable a => Type a -> Name -> Maybe [a] -> Expr a
- Op1 :: forall a1 a. Typeable a1 => Op1 a1 a -> Expr a1 -> Expr a
- Op2 :: forall a1 b a. (Typeable a1, Typeable b) => Op2 a1 b a -> Expr a1 -> Expr b -> Expr a
- Op3 :: forall a1 b c a. (Typeable a1, Typeable b, Typeable c) => Op3 a1 b c a -> Expr a1 -> Expr b -> Expr c -> Expr a
- Label :: forall a. Typeable a => Type a -> String -> Expr a -> Expr a
- data UExpr = Typeable a => UExpr {}
- type DropIdx = Word32
Documentation
Internal representation of Copilot stream expressions.
The Core representation mimics the high-level Copilot stream, but the Core representation contains information about the types of elements in the stream.
Constructors
Const :: forall a. Typeable a => Type a -> a -> Expr a | |
Drop :: forall a. Typeable a => Type a -> DropIdx -> Id -> Expr a | |
Local :: forall a1 a. Typeable a1 => Type a1 -> Type a -> Name -> Expr a1 -> Expr a -> Expr a | |
Var :: forall a. Typeable a => Type a -> Name -> Expr a | |
ExternVar :: forall a. Typeable a => Type a -> Name -> Maybe [a] -> Expr a | |
Op1 :: forall a1 a. Typeable a1 => Op1 a1 a -> Expr a1 -> Expr a | |
Op2 :: forall a1 b a. (Typeable a1, Typeable b) => Op2 a1 b a -> Expr a1 -> Expr b -> Expr a | |
Op3 :: forall a1 b c a. (Typeable a1, Typeable b, Typeable c) => Op3 a1 b c a -> Expr a1 -> Expr b -> Expr c -> Expr a | |
Label :: forall a. Typeable a => Type a -> String -> Expr a -> Expr a |
A untyped expression that carries the information about the type of the expression as a value, as opposed to exposing it at type level (using an existential).