"Show" records with Unicode (Haskell)
print . show
will be show
no matter what you're print
ing twice! A generic signature print
tells you:
print :: Show a => a -> IO ()
So you can just print
create something that directly creates show
. print . show
not required!
If you show
a Char
, you will get an exit code for non-ASCII files - this is just a design decision. If you take "Display Type" and use show
on it first, then you print
ing is not the data type itself, but its representation String
given by an instance of the data type show
.
source to share