summaryrefslogtreecommitdiff
path: root/compiler/ghci/ByteCodeGen.hs
diff options
context:
space:
mode:
authorKrzysztof Gogolewski <krzysztof.gogolewski@tweag.io>2019-05-18 18:08:57 +0200
committerKrzysztof Gogolewski <krzysztof.gogolewski@tweag.io>2019-05-18 18:47:06 +0200
commitfb82da79aed65b076f881b852f2eb98b97859211 (patch)
treebf81437462648895aaaf0e06978e0e0983fd299f /compiler/ghci/ByteCodeGen.hs
parenta5fdd185188fcda595fd712f90864ec7c20cdace (diff)
downloadhaskell-wip/get-hscenv.tar.gz
Introduce HasHscEnv class, parallel to HasDynFlagswip/get-hscenv
Diffstat (limited to 'compiler/ghci/ByteCodeGen.hs')
-rw-r--r--compiler/ghci/ByteCodeGen.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/ghci/ByteCodeGen.hs b/compiler/ghci/ByteCodeGen.hs
index c4a08c4e40..6af9cdf77f 100644
--- a/compiler/ghci/ByteCodeGen.hs
+++ b/compiler/ghci/ByteCodeGen.hs
@@ -1906,8 +1906,8 @@ instance Monad BcM where
instance HasDynFlags BcM where
getDynFlags = BcM $ \st -> return (st, hsc_dflags (bcm_hsc_env st))
-getHscEnv :: BcM HscEnv
-getHscEnv = BcM $ \st -> return (st, bcm_hsc_env st)
+instance HasHscEnv BcM where
+ getHscEnv = BcM $ \st -> return (st, bcm_hsc_env st)
emitBc :: ([FFIInfo] -> ProtoBCO Name) -> BcM (ProtoBCO Name)
emitBc bco