I wrote:
> [...]
> * In the modules Int and Word: The fromInteger methods handle
> the J# cases only, but not the S# cases. Example:
>
> import Word
> main = print ((fromInteger 42)::Word32)
>
> yields
>
> Fail: Word.lhs:573: Non-exhaustive patterns in function fromInteger
> [...]
OK, the Word module has been fixed in the repository, but not the Int
module. Hmmm, looking at the sources, I don't understand the reason why
the IntXY methods for fromInteger use a case while the corresponding
methods in Word don't:
Int.lhs:
[...]
fromInteger (J# s# d#)
= case (integer2Int# s# d#) of { i# -> I8# (intToInt8# i#) }
[...]
Word.lhs:
[...]
fromInteger (J# s# d#) = W8# (wordToWord8# (integer2Word# s# d#))
[...]
Are the XtoY# functions lazy?
Cheers,
Sven
--
Sven Panne Tel.: +49/89/2178-2235
LMU, Institut fuer Informatik FAX : +49/89/2178-2211
LFE Programmier- und Modellierungssprachen Oettingenstr. 67
mailto:[EMAIL PROTECTED] D-80538 Muenchen
http://www.pms.informatik.uni-muenchen.de/mitarbeiter/panne