summaryrefslogtreecommitdiff
path: root/compiler/GHC/Unit/External.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/GHC/Unit/External.hs')
-rw-r--r--compiler/GHC/Unit/External.hs4
1 files changed, 4 insertions, 0 deletions
diff --git a/compiler/GHC/Unit/External.hs b/compiler/GHC/Unit/External.hs
index 4ed3479bf4..04af938c03 100644
--- a/compiler/GHC/Unit/External.hs
+++ b/compiler/GHC/Unit/External.hs
@@ -1,6 +1,7 @@
module GHC.Unit.External
( ExternalUnitCache (..)
, initExternalUnitCache
+ , eucEPS
, ExternalPackageState (..)
, initExternalPackageState
, EpsStats(..)
@@ -59,6 +60,9 @@ newtype ExternalUnitCache = ExternalUnitCache
initExternalUnitCache :: IO ExternalUnitCache
initExternalUnitCache = ExternalUnitCache <$> newIORef initExternalPackageState
+eucEPS :: ExternalUnitCache -> IO ExternalPackageState
+eucEPS = readIORef . euc_eps
+
initExternalPackageState :: ExternalPackageState
initExternalPackageState = EPS
{ eps_is_boot = emptyInstalledModuleEnv