Commit aa6bc700 authored by ian@well-typed.com's avatar ian@well-typed.com

Remove a couple of unneccesary Platform arguments

parent 54affcef
......@@ -19,7 +19,6 @@ module OldCmmLint (
import BlockId
import OldCmm
import CLabel
import Outputable
import OldPprCmm()
import FastString
......@@ -50,10 +49,9 @@ runCmmLint _ l p =
lintCmmDecl :: DynFlags -> (GenCmmDecl h i (ListGraph CmmStmt)) -> CmmLint ()
lintCmmDecl dflags (CmmProc _ lbl (ListGraph blocks))
= addLintInfo (text "in proc " <> pprCLabel platform lbl) $
= addLintInfo (text "in proc " <> ppr lbl) $
let labels = foldl (\s b -> setInsert (blockId b) s) setEmpty blocks
in mapM_ (lintCmmBlock dflags labels) blocks
where platform = targetPlatform dflags
lintCmmDecl _ (CmmData {})
= return ()
......
......@@ -38,13 +38,11 @@ module PprCmmDecl
)
where
import CLabel
import PprCmmExpr
import Cmm
import DynFlags
import Outputable
import Platform
import FastString
import Data.List
......@@ -72,7 +70,7 @@ instance (Outputable d, Outputable info, Outputable i)
ppr t = pprTop t
instance Outputable CmmStatics where
ppr x = sdocWithPlatform $ \platform -> pprStatics platform x
ppr = pprStatics
instance Outputable CmmStatic where
ppr = pprStatic
......@@ -141,9 +139,8 @@ instance Outputable ForeignHint where
-- Strings are printed as C strings, and we print them as I8[],
-- following C--
--
pprStatics :: Platform -> CmmStatics -> SDoc
pprStatics platform (Statics lbl ds)
= vcat ((pprCLabel platform lbl <> colon) : map ppr ds)
pprStatics :: CmmStatics -> SDoc
pprStatics (Statics lbl ds) = vcat ((ppr lbl <> colon) : map ppr ds)
pprStatic :: CmmStatic -> SDoc
pprStatic s = case s of
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment