Ticket #4378: pretty_added_instance_IsString_and_Monoid.dpatch

File pretty_added_instance_IsString_and_Monoid.dpatch, 2.1 KB (added by basvandijk, 3 years ago)
Line 
12 patches for repository http://darcs.haskell.org/packages/pretty:
2
3Fri Oct  8 09:20:41 CEST 2010  Bas van Dijk <v.dijk.bas@gmail.com>
4  * Added instance IsString Doc where fromString = text
5
6Fri Oct  8 09:23:58 CEST 2010  Bas van Dijk <v.dijk.bas@gmail.com>
7  * Added instance Monoid Doc where mempty = empty; mappend = (<>)
8
9New patches:
10
11[Added instance IsString Doc where fromString = text
12Bas van Dijk <v.dijk.bas@gmail.com>**20101008072041
13 Ignore-this: 4244040de2f7fd38f013ec16b2a76c35
14] {
15hunk ./Text/PrettyPrint/HughesPJ.hs 217
16 
17 
18 import Prelude
19+import Data.String ( IsString(fromString) )
20 
21 infixl 6 <>
22 infixl 6 <+>
23hunk ./Text/PrettyPrint/HughesPJ.hs 261
24 -- has height 1, while 'empty' has no height.
25 text    :: String   -> Doc
26 
27+instance IsString Doc where
28+    fromString = text
29+
30 -- | An obsolete function, now identical to 'text'.
31 ptext   :: String   -> Doc
32 
33}
34[Added instance Monoid Doc where mempty = empty; mappend = (<>)
35Bas van Dijk <v.dijk.bas@gmail.com>**20101008072358
36 Ignore-this: d91a4c5c6178aeecffe4352425de0ec1
37] {
38hunk ./Text/PrettyPrint/HughesPJ.hs 217
39 
40 
41 import Prelude
42+import Data.Monoid ( Monoid(mempty, mappend) )
43 import Data.String ( IsString(fromString) )
44 
45 infixl 6 <>
46hunk ./Text/PrettyPrint/HughesPJ.hs 286
47 
48 -- Combining @Doc@ values
49 
50+instance Monoid Doc where
51+    mempty  = empty
52+    mappend = (<>)
53+
54 -- | Beside.
55 -- '<>' is associative, with identity 'empty'.
56 (<>)   :: Doc -> Doc -> Doc
57}
58
59Context:
60
61[Bump version number 1.0.1.1 -> 1.0.1.2
62Ian Lynagh <igloo@earth.li>**20100916162249]
63[Fix doc typo; trac #4298
64Ian Lynagh <igloo@earth.li>**20100912172524]
65[vcat should behave like 'foldr ($$) empty', not 'foldr ($+$) empty', according to the documentation
66Benedikt Huber **20100304102410
67 Ignore-this: 50069337ffc8f0712f8b0e039f40b3b2
68]
69[Bump version to 1.0.1.1
70Ian Lynagh <igloo@earth.li>**20090920141946]
71[Fix "Cabal check" warnings
72Ian Lynagh <igloo@earth.li>**20090811215918]
73[Remove unused imports
74Ian Lynagh <igloo@earth.li>**20090707115854]
75[TAG 2009-06-25
76Ian Lynagh <igloo@earth.li>**20090625160329]
77Patch bundle hash:
78434de10b1986f6d0b246e2460ff80abf2da1f9f3