module Outputable (
Outputable(..), -- Class
- PprStyle,
+ PprStyle, CodeStyle(..),
getPprStyle, withPprStyle, pprDeeper,
codeStyle, ifaceStyle, userStyle, debugStyle, asmStyle,
ifPprDebug, ifNotPprForUser,
showSDoc, printSDoc, printErrs, printDump,
printForC, printForAsm, printForIface,
- pprCols,
+ pprCode, pprCols,
-- error handling
pprPanic, pprPanic#, pprError, pprTrace, assertPprPanic,
import FastString
import qualified Pretty
import Pretty ( Doc, Mode(..), TextDetails(..), fullRender )
-import Util ( panic, assertPanic, panic# )
-import GlaExts ( trace )
+import Util ( panic, assertPanic, panic#, trace )
\end{code}
printForIface :: Handle -> SDoc -> IO ()
printForIface handle doc = printDoc OneLineMode handle (doc PprInterface)
+pprCode :: CodeStyle -> SDoc -> SDoc
+pprCode cs d = withPprStyle (PprCode cs) d
-- showSDoc just blasts it out as a string
showSDoc :: SDoc -> String