projects
/
ghc-hetmet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
7039162
)
[project @ 2005-05-17 13:05:45 by simonmar]
author
simonmar
<unknown>
Tue, 17 May 2005 13:05:45 +0000
(13:05 +0000)
committer
simonmar
<unknown>
Tue, 17 May 2005 13:05:45 +0000
(13:05 +0000)
Add showSDocDump
ghc/compiler/utils/Outputable.lhs
patch
|
blob
|
history
diff --git
a/ghc/compiler/utils/Outputable.lhs
b/ghc/compiler/utils/Outputable.lhs
index
e0e9bbb
..
f870b65
100644
(file)
--- a/
ghc/compiler/utils/Outputable.lhs
+++ b/
ghc/compiler/utils/Outputable.lhs
@@
-38,7
+38,7
@@
module Outputable (
printSDoc, printErrs, printDump,
printForC, printForAsm, printForUser,
pprCode, mkCodeStyle,
printSDoc, printErrs, printDump,
printForC, printForAsm, printForUser,
pprCode, mkCodeStyle,
- showSDoc, showSDocForUser, showSDocDebug,
+ showSDoc, showSDocForUser, showSDocDebug, showSDocDump,
showSDocUnqual, showsPrecSDoc,
pprHsChar, pprHsString,
showSDocUnqual, showsPrecSDoc,
pprHsChar, pprHsString,
@@
-209,9
+209,6
@@
printDump doc = do
hFlush stdout
where
better_doc = doc $$ text ""
hFlush stdout
where
better_doc = doc $$ text ""
- -- We used to always print in debug style, but I want
- -- to try the effect of a more user-ish style (unless you
- -- say -dppr-debug)
printForUser :: Handle -> PrintUnqualified -> SDoc -> IO ()
printForUser handle unqual doc
printForUser :: Handle -> PrintUnqualified -> SDoc -> IO ()
printForUser handle unqual doc
@@
-246,6
+243,9
@@
showSDocUnqual d = show (d (mkUserStyle neverQualify AllTheWay))
showsPrecSDoc :: Int -> SDoc -> ShowS
showsPrecSDoc p d = showsPrec p (d defaultUserStyle)
showsPrecSDoc :: Int -> SDoc -> ShowS
showsPrecSDoc p d = showsPrec p (d defaultUserStyle)
+showSDocDump :: SDoc -> String
+showSDocDump d = show (d PprDump)
+
showSDocDebug :: SDoc -> String
showSDocDebug d = show (d PprDebug)
\end{code}
showSDocDebug :: SDoc -> String
showSDocDebug d = show (d PprDebug)
\end{code}