Haddock 2.x and --hoogle

Duncan Coutts duncan.coutts at worc.ox.ac.uk
Fri Jun 13 16:58:15 EDT 2008


On Fri, 2008-06-13 at 18:56 +0100, Neil Mitchell wrote:
> Hi Duncan,
> 
> In the Cabal-1.4 branch, Distribution.Simple.Haddock, line 143:
> 
>     when (hoogle && isVersion2) $
>       die $ "haddock 2.x does not support the --hoogle flag."
> 
> As of earlier today, that is no longer true.

Great.

>  We have several options:
> 
> * Remove the warning all together - it always supported the --hoogle
> flag, it just never did anything.

Yes that was the problem. It confused people:

http://hackage.haskell.org/trac/hackage/ticket/249

> It should probably have been haddock issuing this warning all along,
> not cabal.

That would have been nice.

> * Make it check for haddock >= 2 && < 2.2

Done.

Fri Jun 13 21:54:45 BST 2008  Duncan Coutts <duncan at haskell.org>
  * haddock-2.2 and later do now support the --hoogle flag
Shall I push this patch? (1/1)  [ynWvpxqadjk], or ? for help: v
[haddock-2.2 and later do now support the --hoogle flag
Duncan Coutts <duncan at haskell.org>**20080613205445] {
hunk ./Distribution/Simple/Haddock.hs 143
-    when (hoogle && isVersion2) $
-      die $ "haddock 2.x does not support the --hoogle flag."
+    when (hoogle && version > Version [2] []
+                 && version < Version [2,2] []) $
+      die $ "haddock 2.0 and 2.1 do not support the --hoogle flag."
}


Duncan



More information about the cabal-devel mailing list