more work on HM interpreter
authorTomáš Musil <tomik.musil@gmail.com>
Wed, 2 Sep 2015 15:30:17 +0000 (17:30 +0200)
committerTomáš Musil <tomik.musil@gmail.com>
Wed, 2 Sep 2015 15:30:17 +0000 (17:30 +0200)
src/HM/Interpreter.hs
src/HM/Lambda.hs [new file with mode: 0644]

index 90f5595..17e1e96 100644 (file)
@@ -16,8 +16,6 @@ import HM
 import HM.Term
 import HM.Parser
 
 import HM.Term
 import HM.Parser
 
-import qualified Lambda as L
-
 data Definition = Definition String TypedTerm
 
 dictionary :: [Definition] -> M.Map VarName TypedTerm
 data Definition = Definition String TypedTerm
 
 dictionary :: [Definition] -> M.Map VarName TypedTerm
diff --git a/src/HM/Lambda.hs b/src/HM/Lambda.hs
new file mode 100644 (file)
index 0000000..e85041c
--- /dev/null
@@ -0,0 +1,15 @@
+module HM.Lambda where
+
+import Control.Monad.State
+import Data.Map as M
+
+import HM.Term
+
+type Env = M.Map VarName Term
+type LI a = State Env a
+
+stripType :: TypedTerm -> Term
+stripType (NTTerm t) = t
+stripType (TTerm t _) = t
+
+