[Haskell-cafe] [ANN] ttc-1.0.0.0 - Textual Type Classes

Henning Thielemann lemming at henning-thielemann.de
Thu Jun 3 05:57:25 UTC 2021


On Thu, 3 Jun 2021, Travis Cardwell via Haskell-Cafe wrote:

> I am happy to announce the 1.0 release of TTC (Textual Type Classes).
>
> The library provides the following functionality:
>
> * The Textual type class is used to convert between common textual data
>  types.  It can be used to write functions that accept or return values
>  of any of these textual data types.
>
> * The Render type class is used to render a value as text.  Avoid bugs
>  by only using Show for debugging/development purposes.

That is, your class is intended for text representation for program users 
(instead of programmers)?

I think a notable difference between Show (which is for programmers) and a 
human readable text formatter should be a control of formatting details.

Currently 'printf' is the way to format human readable text and you can 
control formatting of numbers e.g. by "%d", "%3d", "%03d" etc. It's not 
type safe but better than Show.


More information about the Haskell-Cafe mailing list