diff --git a/Info.hs b/Info.hs index 456375b..d65fd06 100644 --- a/Info.hs +++ b/Info.hs @@ -10,6 +10,7 @@ import Data.Generics import Data.List import Data.Maybe import Data.Ord as O +import Data.Time.Clock import DynFlags (tracingDynFlags) import Desugar import GHC @@ -159,7 +160,7 @@ inModuleContext opt fileName modstr action errmsg = moddef = "module " ++ sanitize modstr ++ " where" header = moddef : imports importsBuf <- Gap.toStringBuffer header - clkTime <- Gap.liftIO getClockTime + clkTime <- Gap.liftIO getCurrentTime setTargets [Target (TargetModule $ mkModuleName modstr) True (Just (importsBuf, clkTime))] doif m t = m >>= \ok -> if ok then t else goNext sanitize = fromMaybe "SomeModule" . listToMaybe . words diff --git a/ghc-mod.cabal b/ghc-mod.cabal index cf6ef8c..20b77d8 100644 --- a/ghc-mod.cabal +++ b/ghc-mod.cabal @@ -53,6 +53,7 @@ Executable ghc-mod , hlint >= 1.7.1 , io-choice , old-time + , time , process , regex-posix , syb