HughesPJ.vcat should behave like 'foldr ($$) empty', not like 'foldr ($+$) empty'
The performance tuning for libraries/pretty applied in June 2008
Tue Jun 24 12:37:15 BST 2008 benedikt.huber@gmail.com
* fillNB bug, lazy vcat
accidentally changed the behavior of vcat to foldr ($+$) empty
, although it should be foldr ($$) empty
, according to the documentation. Fixing this is simple (patch attached).
hunk ./Text/PrettyPrint/HughesPJ.hs 497
-vcat = reduceAB . foldr (above_' True) empty
+vcat = reduceAB . foldr (above_' False) empty
See:
http://www.haskell.org/pipermail/libraries/2008-December/011032.html http://www.haskell.org/pipermail/libraries/2010-March/013067.html
It would be nice to add a test case, but I'm not sure where to put it.
Trac metadata
Trac field | Value |
---|---|
Version | 6.12.1 |
Type | Bug |
TypeOfFailure | OtherFailure |
Priority | normal |
Resolution | Unresolved |
Component | libraries/pretty |
Test case | |
Differential revisions | |
BlockedBy | |
Related | |
Blocking | |
CC | |
Operating system | |
Architecture |