Passing --hoogle to haddock when building base
ndmitchell at gmail.com
Sun Nov 7 13:42:42 EST 2010
> While you're revisiting Hoogle, might you be able to
> work from .haddock and .hi files (via haddock API and
> GHC API/ghci), instead of from sources, making Hoogle
> independent of/separate from Haddock's frontend?
All Hoogle needs is a way to generate a text file listing exactly
what's in which modules. How it gets that file is a separate concern
from the rest of Hoogle - I've gone through lots of methods in the
past, and the Haddock backend has been the one that's worked most
reliably for the longest time period. However, I'm happy to switch if
something works better.
> See also:
> Push/improve Haddock API and .haddock files usage
> The hoogle file looks like Haddock docs (which should
> be in .haddock?, available via Haddock API) plus types (which should be
> avaible from ghci's :browse, or via the GHC API).
Hmm, the more places I have to hack, the more scared I become. In the
past Hoogle did take information from the .hi files (horribly
unstable), from :browse command (horribly slow), and the GHC API (not
easy to use the API, changed regularly and massive linking times). I
didn't even know Haddock had an API, but will take a look.
> I'm having a similar problem for indices needed for
> haskellmode for Vim, and I doubt we can extend
> Haddock for every tool, nor distribute separate files
> for every tool. I don't want to talk people out of
> supporting Hoogle, since the support is already in,
> but I would like a more general solution.
The Hoogle textfile is just a representation of what's in the modules
- it's not Hoogle specific at all. Could the haskellmode for Vim use
the Hoogle textfiles? If not, what would need to be added to the
More information about the Cvs-ghc