category-printf

Highbrow approach to type-safe printf format specifications.

Latest on Hackage:0.1.1.0

This package is not currently in any snapshots. If you're interested in using it, we recommend adding it to Stackage Nightly. Doing so will make builds more reliable, and allow stackage.org to host generated Haddocks.

BSD-3-Clause licensed by Cale Gibbard
Maintained by [email protected]

We use the co-Kleisli category for the comonad of functions out of a fixed monoid to implement a generic combinator library for type-safe format specifications. Works with pretty much anything that's a monoid, with specific support for String, Text (strict/lazy), and ByteString (strict/lazy). Credit to Daniel Patterson for introducing me to something that looked just enough like it ought to be the composition for a category, and Ryan Trinkle for the IsString instance. :)