License | BSD3 |
---|---|
Maintainer | Oleg Grenrus <oleg.grenrus@iki.fi> |
Safe Haskell | None |
Language | Haskell2010 |
- class AnsiPretty a where
- ansiPretty :: a -> Doc
- ansiPrettyList :: [a] -> Doc
- ghcAnsiPretty :: forall a. (Generic a, All2 AnsiPretty (GCode a), GFrom a, GDatatypeInfo a, SingI (GCode a)) => a -> Doc
- ghcAnsiPrettyWith :: forall a. (Generic a, All2 AnsiPretty (GCode a), GFrom a, GDatatypeInfo a, SingI (GCode a)) => AnsiPrettyOpts -> a -> Doc
- sopAnsiPretty :: forall a. (Generic a, HasDatatypeInfo a, All2 AnsiPretty (Code a)) => a -> Doc
- sopAnsiPrettyWith :: forall a. (Generic a, HasDatatypeInfo a, All2 AnsiPretty (Code a)) => AnsiPrettyOpts -> a -> Doc
- sopAnsiPrettyS :: All2 AnsiPretty xss => AnsiPrettyOpts -> SOP I xss -> DatatypeInfo xss -> Doc
- data AnsiPrettyOpts = AnsiPrettyOpts {
- poPrettyNewtype :: ConstructorName -> Doc -> Doc
- poPrettyRecord :: ConstructorName -> [(FieldName, Doc)] -> Doc
- defAnsiPrettyOpts :: AnsiPrettyOpts
- type ConstructorName = String
- type FieldName = String
Class
class AnsiPretty a where Source
Generically derivable colorful analogue of Pretty
Nothing
ansiPretty :: a -> Doc Source
ansiPrettyList :: [a] -> Doc Source
Generics
GHC
ghcAnsiPretty :: forall a. (Generic a, All2 AnsiPretty (GCode a), GFrom a, GDatatypeInfo a, SingI (GCode a)) => a -> Doc Source
ghcAnsiPrettyWith :: forall a. (Generic a, All2 AnsiPretty (GCode a), GFrom a, GDatatypeInfo a, SingI (GCode a)) => AnsiPrettyOpts -> a -> Doc Source
SOP
sopAnsiPretty :: forall a. (Generic a, HasDatatypeInfo a, All2 AnsiPretty (Code a)) => a -> Doc Source
sopAnsiPrettyWith :: forall a. (Generic a, HasDatatypeInfo a, All2 AnsiPretty (Code a)) => AnsiPrettyOpts -> a -> Doc Source
sopAnsiPrettyS :: All2 AnsiPretty xss => AnsiPrettyOpts -> SOP I xss -> DatatypeInfo xss -> Doc Source
Options
data AnsiPrettyOpts Source
AnsiPrettyOpts | |
|
Re-exports
From generics-sop
type ConstructorName = String
The name of a data constructor.