Haddock bug for strict unpacked fields?

Hi, using haddock-2.4.1 and this file:
module Test where
data Test = NonStrict Int | Strict !Int | UnpackedStrict {-# UNPACK #-} !Int
The generated documentation looks like this: data Test Constructors NonStrict Int Strict !Int UnpackedStrict !!Int Note the double '!' in the last constructor. This is not intended behaviour, is it? //Stephan -- Früher hieß es ja: Ich denke, also bin ich. Heute weiß man: Es geht auch so. - Dieter Nuhr

2009/1/21 Stephan Friedrichs
Hi,
using haddock-2.4.1 and this file:
module Test where
data Test = NonStrict Int | Strict !Int | UnpackedStrict {-# UNPACK #-} !Int
The generated documentation looks like this:
data Test Constructors NonStrict Int Strict !Int UnpackedStrict !!Int
Note the double '!' in the last constructor. This is not intended behaviour, is it?
This is the way GHC pretty prints unboxed types, so I thought Haddock should follow the same convention. Hmm, perhaps Haddock should have a chapter about language extensions in its documentation, with a reference to the GHC documentation. That way the language used is at least documented. Not sure if it helps in this case though, since "!!" is probably not documented there. Perhaps we should not display unbox annotations at all since they are an implementation detail, right? We could display one "!" instead, indicating that the argument is strict. David
participants (3)
-
David Waern
-
Johan Tibell
-
Stephan Friedrichs