X-Git-Url: http://git.megacz.com/?p=ghc-hetmet.git;a=blobdiff_plain;f=compiler%2Ftypecheck%2FTcEnv.lhs;h=a23795cf6d3975b0546b4df357df73ec3959a8a4;hp=4c87a12671f75fd9b35e31a4de4aa6aec1171776;hb=3f1b316d7035c55cd712cd39a9981339bcef2e8c;hpb=08efb089bb9a1a9c77df6caefe15b44d6ab5b2d3 diff --git a/compiler/typecheck/TcEnv.lhs b/compiler/typecheck/TcEnv.lhs index 4c87a12..a23795c 100644 --- a/compiler/typecheck/TcEnv.lhs +++ b/compiler/typecheck/TcEnv.lhs @@ -47,7 +47,7 @@ module TcEnv( -- Template Haskell stuff checkWellStaged, spliceOK, bracketOK, tcMetaTy, thLevel, - topIdLvl, + topIdLvl, thTopLevelId, -- New Ids newLocalName, newDFunName, newFamInstTyConName, @@ -604,6 +604,10 @@ tcMetaTy :: Name -> TcM Type tcMetaTy tc_name = tcLookupTyCon tc_name `thenM` \ t -> returnM (mkTyConApp t []) + +thTopLevelId :: Id -> Bool +-- See Note [What is a top-level Id?] in TcSplice +thTopLevelId id = isGlobalId id || isExternalName (idName id) \end{code}