diff options
author | Edward Z. Yang <ezyang@cs.stanford.edu> | 2017-03-25 22:50:55 -0700 |
---|---|---|
committer | Edward Z. Yang <ezyang@cs.stanford.edu> | 2017-04-02 16:39:40 -0700 |
commit | 5fb485a3e1e83a1f5c6acf989be292940229e1a4 (patch) | |
tree | 755ff931bfe2fc94d5985464d1a623b4c8ab06d0 /compiler/typecheck/TcRnExports.hs | |
parent | d4e8ebcd04cc210bd15a1fd7677558e8b04b3da8 (diff) | |
download | haskell-5fb485a3e1e83a1f5c6acf989be292940229e1a4.tar.gz |
Fix recompilation avoidance bug for implementor of hsig.
Summary:
I observed a bug where if I modified the module which implemented
an hsig in another package, GHC would not recompile the signature
in this situation.
The root cause was that we were conflating modules from user
imports, and "system" module dependencies (from signature
merging and instantiation.) So this patch handles them separately.
Signed-off-by: Edward Z. Yang <ezyang@cs.stanford.edu>
Test Plan: validate
Reviewers: simonpj, bgamari, austin
Subscribers: rwbarton, thomie, snowleopard
Differential Revision: https://phabricator.haskell.org/D3381
Diffstat (limited to 'compiler/typecheck/TcRnExports.hs')
-rw-r--r-- | compiler/typecheck/TcRnExports.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/typecheck/TcRnExports.hs b/compiler/typecheck/TcRnExports.hs index 99ab7474ad..35e30a797d 100644 --- a/compiler/typecheck/TcRnExports.hs +++ b/compiler/typecheck/TcRnExports.hs @@ -206,7 +206,8 @@ exports_from_avail (Just (L _ rdr_items)) rdr_env imports this_mod imported_modules = [ imv_name imv - | xs <- moduleEnvElts $ imp_mods imports, imv <- xs ] + | xs <- moduleEnvElts $ imp_mods imports + , imv <- importedByUser xs ] exports_from_item :: ExportAccum -> LIE RdrName -> RnM ExportAccum exports_from_item acc@(ExportAccum ie_names occs exports) |