diff options
author | Alan Zimmerman <alan.zimm@gmail.com> | 2017-11-05 21:49:11 +0200 |
---|---|---|
committer | Alan Zimmerman <alan.zimm@gmail.com> | 2017-11-07 08:30:37 +0200 |
commit | 0ff152c9e633accca48815e26e59d1af1fe44ceb (patch) | |
tree | 2feec6a252ac5a4d2d6a98cd42e64f3ac801893e /compiler/main | |
parent | 275ac8ef0a0081f16abbfb8934e10cf271573768 (diff) | |
download | haskell-0ff152c9e633accca48815e26e59d1af1fe44ceb.tar.gz |
WIP on combining Step 1 and 3 of Trees That Grow
See https://ghc.haskell.org/trac/ghc/wiki/ImplementingTreesThatGrow
Trees that grow extension points are added for
- ValBinds
- HsPat
- HsLit
- HsOverLit
- HsType
- HsTyVarBndr
- HsAppType
- FieldOcc
- AmbiguousFieldOcc
Updates haddock submodule
Test Plan: ./validate
Reviewers: shayan-najd, simonpj, austin, goldfire, bgamari
Subscribers: goldfire, rwbarton, thomie, mpickering
Differential Revision: https://phabricator.haskell.org/D4147
Diffstat (limited to 'compiler/main')
-rw-r--r-- | compiler/main/HscStats.hs | 2 | ||||
-rw-r--r-- | compiler/main/InteractiveEval.hs | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/compiler/main/HscStats.hs b/compiler/main/HscStats.hs index 48b8eccaca..23e5c9289a 100644 --- a/compiler/main/HscStats.hs +++ b/compiler/main/HscStats.hs @@ -102,7 +102,7 @@ ppSourceStats short (L _ (HsModule _ exports imports ldecls _ _)) (inst_method_ds, method_specs, method_inlines, inst_type_ds, inst_data_ds) = sum5 (map inst_info inst_decls) - count_bind (PatBind { pat_lhs = L _ (VarPat _) }) = (1,0,0) + count_bind (PatBind { pat_lhs = L _ (VarPat{}) }) = (1,0,0) count_bind (PatBind {}) = (0,1,0) count_bind (FunBind {}) = (0,1,0) count_bind (PatSynBind {}) = (0,0,1) diff --git a/compiler/main/InteractiveEval.hs b/compiler/main/InteractiveEval.hs index e63d6e3a95..72092d737e 100644 --- a/compiler/main/InteractiveEval.hs +++ b/compiler/main/InteractiveEval.hs @@ -871,7 +871,8 @@ compileParsedExprRemote expr@(L loc _) = withSession $ \hsc_env -> do let expr_fs = fsLit "_compileParsedExpr" expr_name = mkInternalName (getUnique expr_fs) (mkTyVarOccFS expr_fs) loc let_stmt = L loc . LetStmt . L loc . HsValBinds $ - ValBindsIn (unitBag $ mkHsVarBind loc (getRdrName expr_name) expr) [] + ValBindsIn noExt + (unitBag $ mkHsVarBind loc (getRdrName expr_name) expr) [] Just ([_id], hvals_io, fix_env) <- liftIO $ hscParsedStmt hsc_env let_stmt updateFixityEnv fix_env |