From 96b7249d85d3486bc5f3b7e70221ece41794eaed Mon Sep 17 00:00:00 2001 From: simonpj Date: Mon, 13 Jan 2003 13:22:58 +0000 Subject: [PATCH] [project @ 2003-01-13 13:22:58 by simonpj] Comment --- ghc/compiler/typecheck/TcRnMonad.lhs | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/ghc/compiler/typecheck/TcRnMonad.lhs b/ghc/compiler/typecheck/TcRnMonad.lhs index a9746a7..51cd7bc 100644 --- a/ghc/compiler/typecheck/TcRnMonad.lhs +++ b/ghc/compiler/typecheck/TcRnMonad.lhs @@ -189,6 +189,12 @@ defaultDefaultTys :: [Type] defaultDefaultTys = [integerTy, doubleTy] mkImpInstEnv :: DynFlags -> ExternalPackageState -> HomePackageTable -> InstEnv +-- At the moment we (wrongly) build an instance environment from all the +-- modules we have already compiled: +-- (a) eps_inst_env from the external package state +-- (b) all the md_insts in the home package table +-- We should really only get instances from modules below us in the +-- module import tree. mkImpInstEnv dflags eps hpt = foldModuleEnv (add . md_insts . hm_details) (eps_inst_env eps) -- 1.7.10.4