Safe Haskell | None |
---|
The ghc-mod library.
- data Cradle = Cradle {
- cradleCurrentDir :: FilePath
- cradleRootDir :: FilePath
- cradleCabalFile :: Maybe FilePath
- cradlePkgDbStack :: [GhcPkgDb]
- findCradle :: IO Cradle
- data Options = Options {
- outputStyle :: OutputStyle
- hlintOpts :: [String]
- ghcOpts :: [GHCOption]
- operators :: Bool
- detailed :: Bool
- qualified :: Bool
- lineSeparator :: LineSeparator
- newtype LineSeparator = LineSeparator String
- data OutputStyle
- = LispStyle
- | PlainStyle
- defaultOptions :: Options
- type ModuleString = String
- type Expression = String
- bootInfo :: Options -> Cradle -> IO String
- browseModule :: Options -> Cradle -> ModuleString -> IO String
- checkSyntax :: Options -> Cradle -> [FilePath] -> IO String
- lintSyntax :: Options -> FilePath -> IO String
- expandTemplate :: Options -> Cradle -> [FilePath] -> IO String
- infoExpr :: Options -> Cradle -> FilePath -> Expression -> IO String
- typeExpr :: Options -> Cradle -> FilePath -> Int -> Int -> IO String
- listModules :: Options -> Cradle -> IO String
- listLanguages :: Options -> IO String
- listFlags :: Options -> IO String
- debugInfo :: Options -> Cradle -> IO String
- rootInfo :: Options -> Cradle -> IO String
- packageDoc :: Options -> Cradle -> ModuleString -> IO String
- findSymbol :: Options -> Cradle -> Symbol -> IO String
Cradle
The environment where this library is used.
Cradle | |
|
Finding Cradle
.
Find a cabal file by tracing ancestor directories.
Find a sandbox according to a cabal sandbox config
in a cabal directory.
Options
Options | |
|
newtype LineSeparator Source
The type for line separator. Historically, a Null string is used.
defaultOptions :: OptionsSource
A default Options
.
Types
type ModuleString = StringSource
Module name.
type Expression = StringSource
Haskell expression.
IO
utilities
bootInfo :: Options -> Cradle -> IO StringSource
Printing necessary information for front-end booting.
:: Options | |
-> Cradle | |
-> ModuleString | A module name. (e.g. "Data.List") |
-> IO String |
Checking syntax of a target file using GHC. Warnings and errors are returned.
Checking syntax of a target file using hlint. Warnings and errors are returned.
Expanding Haskell Template.
Obtaining information of a target expression. (GHCi's info:)
Obtaining type of a target expression. (GHCi's type:)
listLanguages :: Options -> IO StringSource
Listing language extensions.
packageDoc :: Options -> Cradle -> ModuleString -> IO StringSource
Obtaining the package name and the doc path of a module.