diff options
| author | Krzysztof Gogolewski <krzysztof.gogolewski@tweag.io> | 2022-07-26 17:55:23 +0200 |
|---|---|---|
| committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2022-08-09 02:32:24 -0400 |
| commit | e9dfd26a38182e9c284b7db16cb10fc889eedf9e (patch) | |
| tree | f1f57a251deae310291f05c25dea7d16ed547868 /compiler/GHC/Cmm.hs | |
| parent | 681aa076259c05c626266cf516de7e7c5524eadb (diff) | |
| download | haskell-e9dfd26a38182e9c284b7db16cb10fc889eedf9e.tar.gz | |
Cleanups around pretty-printing
* Remove hack when printing OccNames. No longer needed since e3dcc0d5
* Remove unused `pprCmms` and `instance Outputable Instr`
* Simplify `pprCLabel` (no need to pass platform)
* Remove evil `Show`/`Eq` instances for `SDoc`. They were needed by
ImmLit, but that can take just a String instead.
* Remove instance `Outputable CLabel` - proper output of labels
needs a platform, and is done by the `OutputableP` instance
Diffstat (limited to 'compiler/GHC/Cmm.hs')
| -rw-r--r-- | compiler/GHC/Cmm.hs | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/compiler/GHC/Cmm.hs b/compiler/GHC/Cmm.hs index 7a53042814..3533dc2389 100644 --- a/compiler/GHC/Cmm.hs +++ b/compiler/GHC/Cmm.hs @@ -33,7 +33,7 @@ module GHC.Cmm ( module GHC.Cmm.Expr, -- * Pretty-printing - pprCmms, pprCmmGroup, pprSection, pprStatic + pprCmmGroup, pprSection, pprStatic ) where import GHC.Prelude @@ -379,12 +379,6 @@ pprBBlock (BasicBlock ident stmts) = -- -- These conventions produce much more readable Cmm output. -pprCmms :: (OutputableP Platform info, OutputableP Platform g) - => Platform -> [GenCmmGroup RawCmmStatics info g] -> SDoc -pprCmms platform cmms = pprCode CStyle (vcat (intersperse separator $ map (pdoc platform) cmms)) - where - separator = space $$ text "-------------------" $$ space - pprCmmGroup :: (OutputableP Platform d, OutputableP Platform info, OutputableP Platform g) => Platform -> GenCmmGroup d info g -> SDoc pprCmmGroup platform tops |
