hdiff-0.0.1: Pattern-Expression-based differencing of arbitrary types.

Safe HaskellNone
LanguageHaskell2010

Data.HDiff.Patch.Show

Contents

Synopsis

Documentation

spliced :: Doc ann -> Doc ann -> Doc ann Source #

Given a label and a doc, spliced l d = "[" ++ l ++ "|" ++ d ++ "|]"

showRawPatch :: (HasDatatypeInfo ki fam codes, RendererHO ki) => Holes ki codes (CChange ki codes) v -> [String] Source #

Pretty prints a patch on the terminal

showPatchC :: (HasDatatypeInfo ki fam codes, RendererHO ki) => Holes ki codes (Sum (Conflict ki codes) (CChange ki codes)) at -> [String] Source #

displayPatchC :: (HasDatatypeInfo ki fam codes, RendererHO ki) => Handle -> Holes ki codes (Sum (Conflict ki codes) (CChange ki codes)) at -> IO () Source #

Outputs the result of showPatchC to the specified handle

displayRawPatch :: (HasDatatypeInfo ki fam codes, RendererHO ki) => Handle -> Holes ki codes (CChange ki codes) at -> IO () Source #

Outputs the result of showRawPatch to the specified handle

doubleColumn :: Int -> Doc AnsiStyle -> Doc AnsiStyle -> [String] Source #

Displays two docs in a double column fashion

This is a hacky function. We need to render both the colored and the non-colored versions to calculate the width spacing correctly (see complete in the where clause)

Orphan instances

(HasDatatypeInfo ki fam codes, RendererHO ki, ShowHO phi) => Show (Delta (Holes ki codes phi) at) Source # 
Instance details

Methods

showsPrec :: Int -> Delta (Holes ki codes phi) at -> ShowS #

show :: Delta (Holes ki codes phi) at -> String #

showList :: [Delta (Holes ki codes phi) at] -> ShowS #

(HasDatatypeInfo ki fam codes, RendererHO ki) => Show (CChange ki codes at) Source # 
Instance details

Methods

showsPrec :: Int -> CChange ki codes at -> ShowS #

show :: CChange ki codes at -> String #

showList :: [CChange ki codes at] -> ShowS #

(HasDatatypeInfo ki fam codes, RendererHO ki) => Show (Holes ki codes (Sum (Conflict ki codes) (CChange ki codes)) at) Source # 
Instance details

Methods

showsPrec :: Int -> Holes ki codes (Sum (Conflict ki codes) (CChange ki codes)) at -> ShowS #

show :: Holes ki codes (Sum (Conflict ki codes) (CChange ki codes)) at -> String #

showList :: [Holes ki codes (Sum (Conflict ki codes) (CChange ki codes)) at] -> ShowS #

(HasDatatypeInfo ki fam codes, RendererHO ki) => Show (Holes ki codes (CChange ki codes) at) Source # 
Instance details

Methods

showsPrec :: Int -> Holes ki codes (CChange ki codes) at -> ShowS #

show :: Holes ki codes (CChange ki codes) at -> String #

showList :: [Holes ki codes (CChange ki codes) at] -> ShowS #