Quote:
Originally Posted by Mad_guy
Thanks for the tip. On the second piece of code though, you can't directly convert a Word8 to a Char.
|
I did wonder about that, which is why I put "probably" in my sentence
I did a bit more digging, and it turns out that the "fromIntegral" function is your man, as it converts from one integral type to another (presumably it's integral as in integer, not as in integration):
import Data.Char
char :: Integral a => a -> Char
char = chr . fromIntegral
There: a much more universal char function.