Safe Haskell | None |
---|---|
Language | Haskell98 |
- list :: [String] -> Cabal -> ErrorT String IO [ModuleLocation]
- browse :: [String] -> Cabal -> String -> Maybe ModulePackage -> ErrorT String IO InspectedModule
- browseInspection :: [String] -> Inspection
- langs :: ErrorT String IO [String]
- flags :: ErrorT String IO [String]
- info :: [String] -> Cabal -> FilePath -> String -> GhcModT IO Declaration
- data TypedRegion = TypedRegion {}
- typeOf :: [String] -> Cabal -> FilePath -> Int -> Int -> GhcModT IO [TypedRegion]
- data OutputMessage = OutputMessage {
- errorLocation :: Location
- errorLevel :: OutputMessageLevel
- errorMessage :: String
- check :: [String] -> Cabal -> [FilePath] -> Maybe Project -> GhcModT IO [OutputMessage]
- lint :: [String] -> FilePath -> GhcModT IO [OutputMessage]
- runGhcMod :: (IOish m, MonadCatch m) => Options -> GhcModT m a -> ErrorT String m a
- locateGhcModEnv :: FilePath -> IO (Either Project Cabal)
- ghcModEnvPath :: FilePath -> Either Project Cabal -> FilePath
- ghcModWorker :: Either Project Cabal -> IO (Worker (GhcModT IO))
- type WorkerMap = MVar (Map FilePath (Worker (GhcModT IO)))
- ghcModMultiWorker :: IO (Worker (ReaderT WorkerMap IO))
- dispatch :: FilePath -> GhcModT IO a -> ReaderT WorkerMap IO (Task a)
- waitMultiGhcMod :: Worker (ReaderT WorkerMap IO) -> FilePath -> GhcModT IO a -> ErrorT String IO a
- data GhcModT m a :: (* -> *) -> * -> *
- module Control.Concurrent.Worker
Documentation
browse :: [String] -> Cabal -> String -> Maybe ModulePackage -> ErrorT String IO InspectedModule Source
browseInspection :: [String] -> Inspection Source
data OutputMessage Source
OutputMessage | |
|
ghcModWorker :: Either Project Cabal -> IO (Worker (GhcModT IO)) Source
Create ghc-mod worker for project or for sandbox
ghcModMultiWorker :: IO (Worker (ReaderT WorkerMap IO)) Source
Manage many ghc-mod workers for each project/sandbox
waitMultiGhcMod :: Worker (ReaderT WorkerMap IO) -> FilePath -> GhcModT IO a -> ErrorT String IO a Source
data GhcModT m a :: (* -> *) -> * -> *
This is basically a newtype wrapper around StateT
, ErrorT
, JournalT
and ReaderT
with custom instances for GhcMonad
and it's constraints that
means you can run (almost) all functions from the GHC API on top of GhcModT
transparently.
The inner monad m
should have instances for MonadIO
and
MonadBaseControl
IO
, in the common case this is simply IO
. Most mtl
monads already have MonadBaseControl
IO
instances, see the
monad-control
package.
MonadTrans GhcModT | |
Monad m => MonadReader GhcModEnv (GhcModT m) | |
MonadBaseControl IO m => MonadBaseControl IO (GhcModT m) | |
Monad m => MonadError GhcModError (GhcModT m) | |
MonadBaseControl IO m => MonadBase IO (GhcModT m) | |
MonadState s m => MonadState s (GhcModT m) | |
MonadWriter w m => MonadWriter w (GhcModT m) | |
(Monad m, Functor m) => Alternative (GhcModT m) | |
Monad m => Monad (GhcModT m) | |
Functor m => Functor (GhcModT m) | |
Monad m => MonadPlus (GhcModT m) | |
(Monad m, Functor m) => Applicative (GhcModT m) | |
MonadThrow (GhcModT IO) | |
MonadCatch (GhcModT IO) | |
(Functor m, MonadIO m, MonadBaseControl IO m) => GhcMonad (GhcModT m) | |
(Functor m, MonadIO m, MonadBaseControl IO m) => HasDynFlags (GhcModT m) | |
(MonadIO m, MonadBaseControl IO m) => ExceptionMonad (GhcModT m) | |
MonadIO m => MonadIO (GhcModT m) | |
type StM (GhcModT m) a = StM (StateT GhcModState (ErrorT GhcModError (JournalT GhcModLog (ReaderT GhcModEnv m)))) a |
module Control.Concurrent.Worker