| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Development.IDE.Types.HscEnvEq
Synopsis
- data HscEnvEq
- hscEnv :: HscEnvEq -> HscEnv
- newHscEnvEq :: FilePath -> HscEnv -> [(InstalledUnitId, DynFlags)] -> IO HscEnvEq
- hscEnvWithImportPaths :: HscEnvEq -> HscEnv
- newHscEnvEqPreserveImportPaths :: HscEnv -> [(InstalledUnitId, DynFlags)] -> IO HscEnvEq
- newHscEnvEqWithImportPaths :: Maybe [String] -> HscEnv -> [(InstalledUnitId, DynFlags)] -> IO HscEnvEq
- envImportPaths :: HscEnvEq -> Maybe [String]
- envPackageExports :: HscEnvEq -> IO ExportsMap
- envVisibleModuleNames :: HscEnvEq -> IO (Maybe [ModuleName])
- deps :: HscEnvEq -> [(InstalledUnitId, DynFlags)]
Documentation
An HscEnv with equality. Two values are considered equal
if they are created with the same call to newHscEnvEq.
newHscEnvEq :: FilePath -> HscEnv -> [(InstalledUnitId, DynFlags)] -> IO HscEnvEq Source #
hscEnvWithImportPaths :: HscEnvEq -> HscEnv Source #
Unwrap the HscEnv with the original import paths.
Used only for locating imports
newHscEnvEqPreserveImportPaths :: HscEnv -> [(InstalledUnitId, DynFlags)] -> IO HscEnvEq Source #
newHscEnvEqWithImportPaths :: Maybe [String] -> HscEnv -> [(InstalledUnitId, DynFlags)] -> IO HscEnvEq Source #
envImportPaths :: HscEnvEq -> Maybe [String] Source #
If Just, import dirs originally configured in this env If Nothing, the env import dirs are unaltered
envPackageExports :: HscEnvEq -> IO ExportsMap Source #
envVisibleModuleNames :: HscEnvEq -> IO (Maybe [ModuleName]) Source #
listVisibleModuleNames is a pure function,
but it could panic due to a ghc bug: https://github.com/haskell/haskell-language-server/issues/1365
So it's wrapped in IO here for error handling
If Nothing, listVisibleModuleNames panic