ghc-mod-5.7.0.0: Happy Haskell Programming

Safe HaskellNone
LanguageHaskell2010

Language.Haskell.GhcMod.Monad

Synopsis

Documentation

runGmOutT :: IOish m => Options -> GmOutT m a -> m a Source #

runGhcModT :: IOish m => Options -> GhcModT m a -> m (Either GhcModError a, GhcModLog) Source #

Run a GhcModT m computation.

runGhcModT' :: IOish m => GhcModEnv -> GhcModState -> GhcModT m a -> GmOutT m (Either GhcModError (a, GhcModState), GhcModLog) Source #

Run a computation inside GhcModT providing the RWST environment and initial state. This is a low level function, use it only if you know what to do with GhcModEnv and GhcModState.

You should probably look at runGhcModT instead.

hoistGhcModT :: IOish m => (Either GhcModError a, GhcModLog) -> GhcModT m a Source #

hoistGhcModT result. Embed a GhcModT computation's result into a GhcModT computation. Note that if the computation that returned result modified the state part of GhcModT this cannot be restored.

runGmlT :: IOish m => [Either FilePath ModuleName] -> GmlT m a -> GhcModT m a Source #

Run a GmlT action (i.e. a function in the GhcMonad) in the context of certain files or modules

runGmlT' :: IOish m => [Either FilePath ModuleName] -> (forall gm. GhcMonad gm => DynFlags -> gm DynFlags) -> GmlT m a -> GhcModT m a Source #

Run a GmlT action (i.e. a function in the GhcMonad) in the context of certain files or modules, with updated GHC flags

runGmlTWith :: IOish m => [Either FilePath ModuleName] -> (forall gm. GhcMonad gm => DynFlags -> gm DynFlags) -> (GmlT m a -> GmlT m b) -> GmlT m a -> GhcModT m b Source #

Run a GmlT action (i.e. a function in the GhcMonad) in the context of certain files or modules, with updated GHC flags and a final transformation

runGmPkgGhc :: (IOish m, Gm m) => LightGhc a -> m a Source #

withGhcModEnv :: (IOish m, GmOut m) => FilePath -> Options -> ((GhcModEnv, GhcModLog) -> m a) -> m a Source #

withGhcModEnv' :: (IOish m, GmOut m) => (FilePath -> ((Cradle, GhcModLog) -> m a) -> m a) -> FilePath -> Options -> ((GhcModEnv, GhcModLog) -> m a) -> m a Source #