[Haskell-cafe] Don't make 'show*' functions
Thomas DuBuisson
thomas.dubuisson at gmail.com
Fri Dec 26 06:51:13 EST 2008
Hello cafe,
This is just a small thought, but its been bugging me. We have these things
called type classes for a reason (I like to think). When making a new data
type 'Data', it is not productive to avoid type classes such as 'Show' and
export a 'showData' function.
Examples of what I'm talking about include showHtml, showTrie,
showInstalledPackageInfo...
I know the default derivation (and thus generally accepted) instance of Show
isn't pretty, but that just means to me that we need either more methods
within the Show type class or start using the prettyclass package more.
If the problem is an API issue lets fix Pretty or Show. But this show*
stuff should disappear in the long run.
Tom
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.haskell.org/pipermail/haskell-cafe/attachments/20081226/8489ce22/attachment.htm
More information about the Haskell-Cafe
mailing list