summaryrefslogtreecommitdiff
path: root/compiler/main
diff options
context:
space:
mode:
authorSam Halliday <sam.halliday@gmail.com>2019-08-06 22:02:53 +0100
committerMarge Bot <ben+marge-bot@smart-cactus.org>2019-08-18 16:39:21 -0400
commit993804bf40dea77c36f50ff772d112ec69c8a222 (patch)
tree19113a6c66ba516d2437f390fa0c80717f8ea37b /compiler/main
parentd071627932f61a20223ff0875ed96452f9e81b34 (diff)
downloadhaskell-993804bf40dea77c36f50ff772d112ec69c8a222.tar.gz
expose ModuleInfo.minf_rdr_env for tooling authors
Diffstat (limited to 'compiler/main')
-rw-r--r--compiler/main/GHC.hs4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler/main/GHC.hs b/compiler/main/GHC.hs
index 41e59850c0..87f0d12667 100644
--- a/compiler/main/GHC.hs
+++ b/compiler/main/GHC.hs
@@ -80,6 +80,7 @@ module GHC (
modInfoIsExportedName,
modInfoLookupName,
modInfoIface,
+ modInfoRdrEnv,
modInfoSafe,
lookupGlobalName,
findGlobalAnns,
@@ -1221,6 +1222,9 @@ modInfoLookupName minf name = withSession $ \hsc_env -> do
modInfoIface :: ModuleInfo -> Maybe ModIface
modInfoIface = minf_iface
+modInfoRdrEnv :: ModuleInfo -> Maybe GlobalRdrEnv
+modInfoRdrEnv = minf_rdr_env
+
-- | Retrieve module safe haskell mode
modInfoSafe :: ModuleInfo -> SafeHaskellMode
modInfoSafe = minf_safe