From 17d0932b746599cba8f504bedf45fd5236885677 Mon Sep 17 00:00:00 2001 From: simonpj Date: Tue, 9 Aug 2005 16:58:39 +0000 Subject: [project @ 2005-08-09 16:58:39 by simonpj] Wibble to loadHomeInterface for TH quoting; MERGE to STABLE --- ghc/compiler/rename/RnExpr.lhs | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'ghc/compiler/rename') diff --git a/ghc/compiler/rename/RnExpr.lhs b/ghc/compiler/rename/RnExpr.lhs index ad7ddc522b..c252080670 100644 --- a/ghc/compiler/rename/RnExpr.lhs +++ b/ghc/compiler/rename/RnExpr.lhs @@ -33,7 +33,7 @@ import BasicTypes ( FixityDirection(..) ) import PrelNames ( hasKey, assertIdKey, assertErrorName, loopAName, choiceAName, appAName, arrAName, composeAName, firstAName, negateName, thenMName, bindMName, failMName ) -import Name ( Name, nameOccName ) +import Name ( Name, nameOccName, nameIsLocalOrFrom ) import NameSet import RdrName ( RdrName, emptyGlobalRdrEnv, extendLocalRdrEnv, lookupLocalRdrEnv ) import LoadIface ( loadHomeInterface ) @@ -528,9 +528,10 @@ rnRbinds str rbinds \begin{code} rnBracket (VarBr n) = do { name <- lookupOccRn n - ; loadHomeInterface msg name -- Reason: deprecation checking asumes the - -- home interface is loaded, and this is the - -- only way that is going to happen + ; this_mod <- getModule + ; checkM (nameIsLocalOrFrom this_mod name) $ -- Reason: deprecation checking asumes the + do { loadHomeInterface msg name -- home interface is loaded, and this is the + ; return () } -- only way that is going to happen ; returnM (VarBr name, unitFV name) } where msg = ptext SLIT("Need interface for Template Haskell quoted Name") -- cgit v1.2.1