debian-4.1.2: Modules for working with the Debian package system

Safe Haskell | Safe-Inferred
Language | Haskell2010

Debian.Pretty

Contents

- Re-export

Description

A constructor we can wrap around values to avoid any built in Pretty instance - for example, instance Pretty [a].

- display is now prettyShow
- display' is now prettyText
- ppDisplay is now ppShow
- ppDisplay' is now ppText

Synopsis

- newtype PP a = PP {
  - unPP :: a
  }
- prettyText :: Pretty a => a -> Text
- ppPrint :: Pretty (PP a) => a -> Doc
- ppShow :: Pretty (PP a) => a -> String
- ppText :: Pretty (PP a) => a -> Text
- prettyShow :: Pretty a => a -> String

# Documentation

newtype PP a Source #

This type is wrapped around values before we pretty print them so we can write our own Pretty instances for common types without polluting the name space of clients of this package with instances they don't want.

Constructors

PP |

Fields

- unPP :: a

#### Instances

Instances details

Functor PP Source # |
Instance details Defined in Debian.Pretty Methods fmap :: (a -> b) -> PP a -> PP b Source # (<$) :: a -> PP b -> PP a Source #
Pretty (PP ChangeLog) Source # |
Instance details Defined in Debian.Changes Methods pretty :: PP ChangeLog -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP ChangeLog -> Doc Source #
Pretty (PP ChangeLogEntry) Source # |
Instance details Defined in Debian.Changes Methods pretty :: PP ChangeLogEntry -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP ChangeLogEntry -> Doc Source #
Pretty (PP ChangedFileSpec) Source # |
Instance details Defined in Debian.Changes Methods pretty :: PP ChangedFileSpec -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP ChangedFileSpec -> Doc Source #
Pretty (PP ChangesFile) Source # |
Instance details Defined in Debian.Changes Methods pretty :: PP ChangesFile -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP ChangesFile -> Doc Source #
Pretty (PP ArchitectureReq) Source # |
Instance details Defined in Debian.Relation.Common Methods pretty :: PP ArchitectureReq -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP ArchitectureReq -> Doc Source #
Pretty (PP BinPkgName) Source # |
Instance details Defined in Debian.Relation.Common Methods pretty :: PP BinPkgName -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP BinPkgName -> Doc Source #
Pretty (PP OrRelation) Source # |
Instance details Defined in Debian.Relation.Common Methods pretty :: PP OrRelation -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP OrRelation -> Doc Source #
Pretty (PP Relation) Source # |
Instance details Defined in Debian.Relation.Common Methods pretty :: PP Relation -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP Relation -> Doc Source #
Pretty (PP Relations) Source # | Wrap `PP` around type synonyms that might overlap with the `Pretty [a]` instance.
Instance details Defined in Debian.Relation.Common Methods pretty :: PP Relations -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP Relations -> Doc Source #
Pretty (PP SrcPkgName) Source # |
Instance details Defined in Debian.Relation.Common Methods pretty :: PP SrcPkgName -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP SrcPkgName -> Doc Source #
Pretty (PP VersionReq) Source # |
Instance details Defined in Debian.Relation.Common Methods pretty :: PP VersionReq -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP VersionReq -> Doc Source #
Pretty (PP DebianVersion) Source # |
Instance details Defined in Debian.Version.Common Methods pretty :: PP DebianVersion -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP DebianVersion -> Doc Source #
Pretty (PP Text) Source # |
Instance details Defined in Debian.Pretty Methods pretty :: PP Text -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP Text -> Doc Source #
Pretty (PP String) Source # |
Instance details Defined in Debian.Pretty Methods pretty :: PP String -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP String -> Doc Source #
Pretty (PP a) => Pretty (PP (Maybe a)) Source # |
Instance details Defined in Debian.Pretty Methods pretty :: PP (Maybe a) -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP (Maybe a) -> Doc Source #
Pretty (PP [ChangeLogEntry]) Source # |
Instance details Defined in Debian.Changes Methods pretty :: PP [ChangeLogEntry] -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP [ChangeLogEntry] -> Doc Source #
Pretty (PP [DebSource]) Source # |
Instance details Defined in Debian.Sources Methods pretty :: PP [DebSource] -> Doc Source # prettyVersioned :: CabalSpecVersion -> PP [DebSource] -> Doc Source #

prettyText :: Pretty a => a -> Text Source #

ppPrint :: Pretty (PP a) => a -> Doc Source #

ppShow :: Pretty (PP a) => a -> String Source #

ppText :: Pretty (PP a) => a -> Text Source #

# Re-export

prettyShow :: Pretty a => a -> String Source #