summaryrefslogtreecommitdiff
path: root/compiler/GHC/Driver
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/GHC/Driver')
-rw-r--r--compiler/GHC/Driver/Pipeline.hs2
-rw-r--r--compiler/GHC/Driver/Pipeline/Execute.hs8
2 files changed, 6 insertions, 4 deletions
diff --git a/compiler/GHC/Driver/Pipeline.hs b/compiler/GHC/Driver/Pipeline.hs
index cd2c3e93be..242887b353 100644
--- a/compiler/GHC/Driver/Pipeline.hs
+++ b/compiler/GHC/Driver/Pipeline.hs
@@ -589,7 +589,7 @@ compileForeign hsc_env lang stub_c = do
-- This should never happen as viaCPipeline should only return `Nothing` when the stop phase is `StopC`.
-- and the same should never happen for asPipeline
-- Future refactoring to not check StopC for this case
- Nothing -> pprPanic "compileForeign" (ppr stub_c)
+ Nothing -> pprPanic "compileForeign" (text stub_c)
Just fp -> return fp
compileEmptyStub :: DynFlags -> HscEnv -> FilePath -> ModLocation -> ModuleName -> IO ()
diff --git a/compiler/GHC/Driver/Pipeline/Execute.hs b/compiler/GHC/Driver/Pipeline/Execute.hs
index f19cb05ab5..72a9e49278 100644
--- a/compiler/GHC/Driver/Pipeline/Execute.hs
+++ b/compiler/GHC/Driver/Pipeline/Execute.hs
@@ -860,9 +860,11 @@ getOutputFilename logger tmpfs stop_phase output basename dflags next_phase mayb
| otherwise = newTempName logger tmpfs (tmpDir dflags) TFL_CurrentModule
suffix
where
- getOutputFile_ dflags = case outputFile_ dflags of
- Nothing -> pprPanic "SpecificFile: No filename" (ppr $ (dynamicNow dflags, outputFile_ dflags, dynOutputFile_ dflags))
- Just fn -> fn
+ getOutputFile_ dflags =
+ case outputFile_ dflags of
+ Nothing -> pprPanic "SpecificFile: No filename" (ppr (dynamicNow dflags) $$
+ text (fromMaybe "-" (dynOutputFile_ dflags)))
+ Just fn -> fn
hcsuf = hcSuf dflags
odir = objectDir dflags