Safe Haskell | None |
---|---|
Language | Haskell98 |
- data SessionTarget
- = SessionGhci
- | SessionGhc [String]
- type GhcM a = MGhcT SessionTarget (LogT IO) a
- type GhcWorker = Worker (MGhcT SessionTarget (LogT IO))
- newtype MGhcT s m a = MGhcT {}
- runGhcM :: MonadLog m => Maybe FilePath -> GhcM a -> m a
- ghcWorker :: MonadLog m => m GhcWorker
- workerSession :: SessionTarget -> GhcM ()
- ghcRun :: GhcMonad m => [String] -> m a -> m a
- withFlags :: GhcMonad m => m a -> m a
- modifyFlags :: GhcMonad m => (DynFlags -> DynFlags) -> m ()
- addCmdOpts :: (MonadLog m, GhcMonad m) => [String] -> m ()
- setCmdOpts :: (MonadLog m, GhcMonad m) => [String] -> m ()
- importModules :: GhcMonad m => [String] -> m ()
- preludeModules :: [String]
- evaluate :: GhcMonad m => String -> m String
- clearTargets :: GhcMonad m => m ()
- makeTarget :: GhcMonad m => String -> Maybe String -> m Target
- loadTargets :: GhcMonad m => [Target] -> m ()
- listPackages :: GhcMonad m => m [ModulePackage]
- spanRegion :: SrcSpan -> Region
- withCurrentDirectory :: GhcMonad m => FilePath -> m a -> m a
- logToChan :: Chan (Note OutputMessage) -> LogAction
- logToNull :: LogAction
- data Ghc a :: * -> *
- newtype LogT m a :: (* -> *) -> * -> * = LogT {}
- module HsDev.Tools.Ghc.MGhc
- module Control.Concurrent.Worker
Workers
data SessionTarget Source #
Multi-session ghc monad
Monad m => MonadState (SessionState s) (MGhcT s m) Source # | |
Monad m => MonadReader (Maybe FilePath) (MGhcT s m) Source # | |
Monad m => Monad (MGhcT s m) Source # | |
Functor m => Functor (MGhcT s m) Source # | |
Monad m => Applicative (MGhcT s m) Source # | |
MonadIO m => MonadIO (MGhcT s m) Source # | |
MonadThrow m => MonadThrow (MGhcT s m) Source # | |
MonadCatch m => MonadCatch (MGhcT s m) Source # | |
MonadMask m => MonadMask (MGhcT s m) Source # | |
ExceptionMonad m => GhcMonad (MGhcT s m) Source # | |
MonadIO m => HasDynFlags (MGhcT s m) Source # | |
ExceptionMonad m => ExceptionMonad (MGhcT s m) Source # | |
MonadLog m => MonadLog (MGhcT s m) Source # | |
workerSession :: SessionTarget -> GhcM () Source #
Create session with options
Initializers and actions
addCmdOpts :: (MonadLog m, GhcMonad m) => [String] -> m () Source #
Add options without reinit session
importModules :: GhcMonad m => [String] -> m () Source #
Import some modules
preludeModules :: [String] Source #
Default interpreter modules
clearTargets :: GhcMonad m => m () Source #
Clear loaded targets
makeTarget :: GhcMonad m => String -> Maybe String -> m Target Source #
Make target with its source code optional
loadTargets :: GhcMonad m => [Target] -> m () Source #
Load all targets
Utils
listPackages :: GhcMonad m => m [ModulePackage] Source #
Get list of installed packages
spanRegion :: SrcSpan -> Region Source #
Get region of SrcSpan
withCurrentDirectory :: GhcMonad m => FilePath -> m a -> m a Source #
Set current directory and restore it after action
logToChan :: Chan (Note OutputMessage) -> LogAction Source #
Log ghc warnings and errors as to chan You may have to apply recalcTabs on result notes
newtype LogT m a :: (* -> *) -> * -> * #
Monad m => MonadReader Log (LogT m) | |
Monad m => Monad (LogT m) | |
Functor m => Functor (LogT m) | |
Applicative m => Applicative (LogT m) | |
MonadIO m => MonadIO (LogT m) | |
MonadThrow m => MonadThrow (LogT m) | |
MonadCatch m => MonadCatch (LogT m) | |
MonadMask m => MonadMask (LogT m) | |
(MonadIO m, MonadMask m) => MonadLog (LogT m) | |
module HsDev.Tools.Ghc.MGhc
module Control.Concurrent.Worker