1
1
mirror of https://github.com/github/semantic.git synced 2025-01-03 13:02:37 +03:00

Define an existential abstraction over Builtin.

This commit is contained in:
Rob Rix 2018-05-28 11:52:05 -04:00
parent d0e07f76b8
commit 5116d52da7

View File

@ -86,3 +86,9 @@ data Primitive result where
runPrimitive :: (Effectful m, Member Trace effects) => m (Primitive ': effects) a -> m effects a
runPrimitive = interpret (\ (Prim builtin params) -> case builtin of
Print -> trace params)
data SomeBuiltin where
SomeBuiltin :: Builtin arg return -> SomeBuiltin
deriving instance Show SomeBuiltin