From: Tomáš Musil Date: Mon, 31 Aug 2015 16:58:38 +0000 (+0200) Subject: remove unnecessary X-Git-Url: http://git.tomasm.cz/fp.git/commitdiff_plain/79ff57615dcea00a035f125f8d8d77d5d128de5f?ds=sidebyside;hp=afc027ed2ff6fdf1aba286c4b6501ee240e36183 remove unnecessary --- diff --git a/src/HM.hs b/src/HM.hs index 9c4aa76..8f6df2f 100644 --- a/src/HM.hs +++ b/src/HM.hs @@ -16,7 +16,6 @@ module HM , TypedTerm(..) -- * Type inference , algW - , runTI ) where import Control.Monad.Except @@ -123,7 +122,7 @@ ti e (NTTerm (Let x a b)) = do return (s1 `composeSub` s2, t2) -algW :: TypedTerm -> TI Type -algW t = do +algW :: TypedTerm -> Either String Type +algW t = fst . runTI $ do (s, u) <- ti Map.empty t return $ substituteT s u