Safe Haskell | None |
---|---|
Language | Haskell2010 |
Simple string-based printers.
NOTE “Printing” here means rendering / displaying / showing
(not stdout
or putStrLn
, necessarily).
Synopsis
- type SimplePrint a = a -> String
Documentation
type SimplePrint a = a -> String Source #
Simple printer.
a Type Alias for showing strings:
show :: (Show a) => SimplePrint
a
Usage:
-- an example printer:
printVerbosity :: SimpleParse
Verbosity
printVerbosity = case
Concise -> "concise"
Verbose -> "verbose"
-- for this type:
data Verbosity = Concise | Verbose