[Type-constraints] Removed unnecessary definitions

This commit is contained in:
Nikolay Yakimov
2016-01-19 22:52:06 +03:00
parent 960a49c1ed
commit 39659b2917
2 changed files with 0 additions and 10 deletions

View File

@@ -30,14 +30,12 @@ import qualified Data.Map as M
----------------------------------------------------------------
instance HasType (LHsExpr Id) where
getId _ _e = return []
getType tcm e = do
hs_env <- G.getSession
mbe <- liftIO $ Gap.deSugar tcm e hs_env
return $ (G.getLoc e, ) <$> CoreUtils.exprType <$> mbe
instance HasType (LPat Id) where
getId _ = return . G.collectPatBinders
getType _ (G.L spn pat) = return $ Just (spn, hsPatType pat)
----------------------------------------------------------------
@@ -89,12 +87,6 @@ listifySpans tcs lc = listifyStaged TypeChecker p tcs
where
p (L spn _) = G.isGoodSrcSpan spn && spn `G.spans` lc
listifyAbsBinds :: TypecheckedSource -> [Located (G.HsBind Id)]
listifyAbsBinds = listifyStaged TypeChecker p
where
p (L _ G.AbsBinds{}) = True
p _ = False
listifyParsedSpans :: Typeable a => ParsedSource -> (Int, Int) -> [Located a]
listifyParsedSpans pcs lc = listifyStaged Parser p pcs
where