diff options
Diffstat (limited to 'src/HaskellCodeExplorer')
-rw-r--r-- | src/HaskellCodeExplorer/AST/TypecheckedSource.hs | 33 |
1 files changed, 0 insertions, 33 deletions
diff --git a/src/HaskellCodeExplorer/AST/TypecheckedSource.hs b/src/HaskellCodeExplorer/AST/TypecheckedSource.hs index 3ca9194..72b3c4a 100644 --- a/src/HaskellCodeExplorer/AST/TypecheckedSource.hs +++ b/src/HaskellCodeExplorer/AST/TypecheckedSource.hs @@ -85,7 +85,6 @@ import GHC.Data.FastString ( FastString , mkFastString , unpackFS ) --- import GHC.Driver.Ppr ( pprTrace ) import GHC.Hs ( ABExport(..) , ApplicativeArg(..) , ArithSeqInfo(..) @@ -131,10 +130,6 @@ import GHC.Hs ( ABExport(..) , selectorAmbiguousFieldOcc ) import GHC.Hs.Binds ( RecordPatSynField(..) ) --- import GHC.Hs.Dump ( BlankEpAnnotations(..) --- , BlankSrcSpan(..) --- , showAstData --- ) import GHC.Hs.Expr ( HsExpansion(..) , HsWrap(..) , XXExprGhcTc(..) @@ -174,7 +169,6 @@ import GHC.Types.Var ( Id import GHC.Types.Var.Env ( TidyEnv ) import GHC.Unit.State ( UnitState ) import GHC.Utils.Misc ( thenCmp ) --- import GHC.Utils.Outputable ( showPprUnsafe ) import HaskellCodeExplorer.GhcUtils import qualified HaskellCodeExplorer.Types as HCE import Prelude hiding ( span ) @@ -601,11 +595,6 @@ foldTypecheckedSource :: LHsBinds GhcTc -> State ASTState () foldTypecheckedSource = foldLHsBindsLR foldLHsExpr :: LHsExpr GhcTc -> State ASTState (Maybe Type) --- foldLHsExpr lhe --- | pprTrace "foldLHsExpr" --- (showAstData NoBlankSrcSpan NoBlankEpAnnotations lhe) --- False --- = undefined foldLHsExpr lhe@(L _ (HsVar _ (L _ identifier))) = restoreTidyEnv $ do (identifier', mbTypes) <- tidyIdentifier identifier addIdentifierToIdSrcSpanMap (getLocA lhe) identifier' mbTypes @@ -1056,11 +1045,6 @@ foldLHsBindLR (L _ (PatSynBind _ PSB {..})) _ = restoreTidyEnv $ do return Nothing foldLPat :: LPat GhcTc -> State ASTState (Maybe Type) --- foldLPat lp --- | pprTrace "foldLPat" --- (showAstData NoBlankSrcSpan NoBlankEpAnnotations lp) --- False --- = undefined foldLPat ( L _span (XPat _ )) = return Nothing foldLPat lp@(L _ (VarPat _ (L _ identifier))) = do (identifier', _) <- tidyIdentifier identifier @@ -1100,23 +1084,6 @@ foldLPat (L _span (SumPat _ pat _ _)) = do -- TODO _ <- foldLPat pat return Nothing --- no more conpatin / conpatout, just conpat (in the wildcard pattern _) --- original --- foldLPat (ghcDL -> L _span (ConPatIn _ _)) = return Nothing --- foldLPat (ghcDL -> L span pat@ConPatOut {..}) = do --- let (L idSpan conLike) = pat_con --- conId = --- case conLike of --- RealDataCon dc -> dataConWorkId dc --- PatSynCon ps -> patSynId ps --- typ = conLikeResTy (unLoc pat_con) pat_arg_tys --- (identifier', mbTypes) <- tidyIdentifier conId --- addIdentifierToIdSrcSpanMap idSpan identifier' mbTypes --- typ' <- tidyType typ --- addExprInfo span (Just typ') "ConPatOut" (patSort pat) --- _ <- foldHsConPatDetails pat_args --- return . Just . varType $ identifier' - foldLPat lp@(L _ pat@(ConPat ConPatTc {..} (L _ conLike) args)) = do let typ = conLikeResTy conLike cpt_arg_tys typ' <- tidyType typ |