summaryrefslogtreecommitdiff
path: root/app/Env.hs
diff options
context:
space:
mode:
Diffstat (limited to 'app/Env.hs')
-rw-r--r--app/Env.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/app/Env.hs b/app/Env.hs
index e873711..82bf9d0 100644
--- a/app/Env.hs
+++ b/app/Env.hs
@@ -1,6 +1,6 @@
module Env where
-import Code (Interp(..), PrlgEnv)
+import Code (Interp(..), InterpFn, PrlgEnv)
import Control.Monad.Trans.State.Lazy (gets, modify)
import qualified IR
@@ -20,3 +20,6 @@ findAtom :: String -> Env.PrlgEnv Int
findAtom = withStrTable . flip IR.strtablize
type PrlgEnv a = Code.PrlgEnv a
+
+prlgError :: String -> InterpFn
+prlgError = pure . pure . Left