summaryrefslogtreecommitdiff
path: root/hadrian
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2021-12-18 19:31:35 -0500
committerMarge Bot <ben+marge-bot@smart-cactus.org>2022-04-28 18:55:20 -0400
commitda8ae7f273fcbb57ab5630aa1160c586e64fc0ed (patch)
treef59dba1b912245da32db7ab8d7e9b1fff62d6e2c /hadrian
parent769279e65a67ae67bd707152f82af6b1b1bbf133 (diff)
downloadhaskell-da8ae7f273fcbb57ab5630aa1160c586e64fc0ed.tar.gz
hadrian: Clean up flavour transformer definitions
Previously the `ipe` and `omit_pragmas` transformers were hackily defined using the textual key-value syntax. Fix this.
Diffstat (limited to 'hadrian')
-rw-r--r--hadrian/src/Flavour.hs7
1 files changed, 3 insertions, 4 deletions
diff --git a/hadrian/src/Flavour.hs b/hadrian/src/Flavour.hs
index 7a42e6df3d..02d94448f6 100644
--- a/hadrian/src/Flavour.hs
+++ b/hadrian/src/Flavour.hs
@@ -206,10 +206,9 @@ enableIPE = addArgs
? pure ["-finfo-table-map", "-fdistinct-constructor-tables"]
enableLateCCS :: Flavour -> Flavour
-enableLateCCS =
- let Right kv = parseKV "stage1.*.ghc.hs.opts += -fprof-late"
- Right transformer = applySetting kv
- in transformer
+enableLateCCS = addArgs
+ $ notStage0 ? builder (Ghc CompileHs)
+ ? arg "-fprof-late"
-- | Enable assertions for the stage2 compiler
enableAssertions :: Flavour -> Flavour