-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | A documentation-generation tool for Haskell libraries -- -- Haddock is a documentation-generation tool for Haskell libraries @package haddock @version 2.6.0 module Distribution.Haddock -- | Read a Haddock (.haddock) interface file. Return either an -- InterfaceFile or an error message. -- -- This function can be called in two ways. Within a GHC session it will -- update the use and update the session's name cache. Outside a GHC -- session a new empty name cache is used. The function is therefore -- generic in the monad being used. The exact monad is whichever monad -- the first argument, the getter and setter of the name cache, requires. readInterfaceFile :: (MonadIO m) => NameCacheAccessor m -> FilePath -> m (Either String InterfaceFile) nameCacheFromGhc :: NameCacheAccessor Ghc freshNameCache :: NameCacheAccessor IO type NameCacheAccessor m = (m NameCache, NameCache -> m ()) data InterfaceFile InterfaceFile :: LinkEnv -> [InstalledInterface] -> InterfaceFile ifLinkEnv :: InterfaceFile -> LinkEnv ifInstalledIfaces :: InterfaceFile -> [InstalledInterface] type LinkEnv = Map Name Module -- | A smaller version of Interface that we can get from the Haddock -- interface files. data InstalledInterface InstalledInterface :: Module -> HaddockModInfo Name -> Map Name (DocForDecl Name) -> [Name] -> [Name] -> [DocOption] -> Map Name [Name] -> InstalledInterface -- | The module represented by this interface instMod :: InstalledInterface -> Module -- | Textual information about the module instInfo :: InstalledInterface -> HaddockModInfo Name -- | Everything declared in the module (including subordinates) that has -- docs instDocMap :: InstalledInterface -> Map Name (DocForDecl Name) -- | All names exported by this module instExports :: InstalledInterface -> [Name] -- | All the visible names exported by this module For a name to be -- visible, it has to: -- -- -- -- Basically, a visible name is a name that will show up in the -- documentation for this module. instVisibleExports :: InstalledInterface -> [Name] -- | The Haddock options for this module (prune, ignore-exports, etc) instOptions :: InstalledInterface -> [DocOption] instSubMap :: InstalledInterface -> Map Name [Name] -- | A DocName is an identifier that may be documented. The -- Module component specifies the place which we want to link to -- in the documentation. data DocName Documented :: Name -> Module -> DocName Undocumented :: Name -> DocName -- | The OccName belonging to this name docNameOcc :: DocName -> OccName