summaryrefslogtreecommitdiff
path: root/compiler
diff options
context:
space:
mode:
authorGabor Greif <ggreif@gmail.com>2020-01-03 21:22:36 -0500
committerBen Gamari <ben@well-typed.com>2020-01-03 21:22:36 -0500
commitb2e0323f318959c879629ef277f6433b44473c4b (patch)
treefde32aab739fa509fb8ec8e478aca10ccdc07491 /compiler
parentb84c09d533faf576c406ce9f7163efecf3037787 (diff)
downloadhaskell-b2e0323f318959c879629ef277f6433b44473c4b.tar.gz
Simplify mrStr
Diffstat (limited to 'compiler')
-rw-r--r--compiler/cmm/CmmType.hs9
-rw-r--r--compiler/main/DriverPipeline.hs2
-rw-r--r--compiler/main/Packages.hs2
3 files changed, 3 insertions, 10 deletions
diff --git a/compiler/cmm/CmmType.hs b/compiler/cmm/CmmType.hs
index 43d23c7ee7..f8ac71ac89 100644
--- a/compiler/cmm/CmmType.hs
+++ b/compiler/cmm/CmmType.hs
@@ -175,14 +175,7 @@ instance Outputable Width where
ppr rep = ptext (mrStr rep)
mrStr :: Width -> PtrString
-mrStr W8 = sLit("W8")
-mrStr W16 = sLit("W16")
-mrStr W32 = sLit("W32")
-mrStr W64 = sLit("W64")
-mrStr W128 = sLit("W128")
-mrStr W256 = sLit("W256")
-mrStr W512 = sLit("W512")
-
+mrStr = sLit . show
-------- Common Widths ------------
diff --git a/compiler/main/DriverPipeline.hs b/compiler/main/DriverPipeline.hs
index 62a4826edb..fd2dc261c4 100644
--- a/compiler/main/DriverPipeline.hs
+++ b/compiler/main/DriverPipeline.hs
@@ -1250,7 +1250,7 @@ runPhase (RealPhase cc_phase) input_fn dflags
-- pass -D or -optP to preprocessor when compiling foreign C files
-- (#16737). Doing it in this way is simpler and also enable the C
- -- compiler to performs preprocessing and parsing in a single pass,
+ -- compiler to perform preprocessing and parsing in a single pass,
-- but it may introduce inconsistency if a different pgm_P is specified.
let more_preprocessor_opts = concat
[ ["-Xpreprocessor", i]
diff --git a/compiler/main/Packages.hs b/compiler/main/Packages.hs
index 9feffe7cb5..c1ab3d62c3 100644
--- a/compiler/main/Packages.hs
+++ b/compiler/main/Packages.hs
@@ -1444,7 +1444,7 @@ mkPackageState dflags dbs preload0 = do
we build a mapping saying what every in scope module name points to.
-}
- -- This, and the other reverse's that you will see, are due to the face that
+ -- This, and the other reverse's that you will see, are due to the fact that
-- packageFlags, pluginPackageFlags, etc. are all specified in *reverse* order
-- than they are on the command line.
let other_flags = reverse (packageFlags dflags)