X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=ghc%2Fcompiler%2Ftypecheck%2FTcSplice.lhs;fp=ghc%2Fcompiler%2Ftypecheck%2FTcSplice.lhs;h=376b3eaffdf911fafeb22ee89e86a6bec0c1e5f4;hb=853e20a3eb86137cdb8accf69c6caa9db83a3d34;hp=67b4e281d95003d037a739a992fbae0fd3ddf25c;hpb=ca739e852566d7e0bfd594e6d7bf08da04f78d3c;p=ghc-hetmet.git diff --git a/ghc/compiler/typecheck/TcSplice.lhs b/ghc/compiler/typecheck/TcSplice.lhs index 67b4e28..376b3ea 100644 --- a/ghc/compiler/typecheck/TcSplice.lhs +++ b/ghc/compiler/typecheck/TcSplice.lhs @@ -475,7 +475,7 @@ lookupThName th_name -> do { mb_name <- lookupSrcOcc_maybe rdr_name ; case mb_name of - Just name -> return name ; + Just name -> return name Nothing -> failWithTc (notInScope th_name) } } where @@ -490,8 +490,8 @@ tcLookupTh :: Name -> TcM TcTyThing -- tcLookup, failure is a bug. tcLookupTh name = do { (gbl_env, lcl_env) <- getEnvs - ; case lookupNameEnv (tcl_env lcl_env) name of - Just thing -> returnM thing + ; case lookupNameEnv (tcl_env lcl_env) name of { + Just thing -> returnM thing; Nothing -> do { if nameIsLocalOrFrom (tcg_mod gbl_env) name then -- It's defined in this module @@ -507,7 +507,7 @@ tcLookupTh name ; return (AGlobal thing) } -- Imported names should always be findable; -- if not, we fail hard in tcImportDecl - }}} + }}}} mk_uniq :: Int# -> Unique mk_uniq u = mkUniqueGrimily (I# u)