summaryrefslogtreecommitdiff
path: root/utils/mkUserGuidePart/Options/CodeGen.hs
diff options
context:
space:
mode:
authorBen Gamari <ben@smart-cactus.org>2015-09-25 18:00:19 +0200
committerBen Gamari <ben@smart-cactus.org>2015-11-23 17:47:41 +0100
commit7aaeaf81ea95c36fe1dc4da449cf6092a792fd09 (patch)
tree79703e6d9db2f81507272d9efd1a5952b17c7924 /utils/mkUserGuidePart/Options/CodeGen.hs
parentbb249aa749c82590823855e970bcc1c4d4b23523 (diff)
downloadhaskell-7aaeaf81ea95c36fe1dc4da449cf6092a792fd09.tar.gz
Support multiple debug output levels
We now only strip block information from DebugBlocks when compiling with `-g1`, intended to be used when only minimal debug information is desired. `-g2` is assumed when `-g` is passed without any integer argument. Differential Revision: https://phabricator.haskell.org/D1281
Diffstat (limited to 'utils/mkUserGuidePart/Options/CodeGen.hs')
-rw-r--r--utils/mkUserGuidePart/Options/CodeGen.hs7
1 files changed, 7 insertions, 0 deletions
diff --git a/utils/mkUserGuidePart/Options/CodeGen.hs b/utils/mkUserGuidePart/Options/CodeGen.hs
index 0d9cabb27d..9939d9e100 100644
--- a/utils/mkUserGuidePart/Options/CodeGen.hs
+++ b/utils/mkUserGuidePart/Options/CodeGen.hs
@@ -32,4 +32,11 @@ codegenOptions =
, flagDescription = "Generate object code"
, flagType = DynamicFlag
}
+ , flag { flagName = "-g⟨n⟩"
+ , flagDescription =
+ "Produce DWARF debug information in compiled object files." ++
+ "⟨n⟩ can be 0, 1, or 2, with higher numbers producing richer " ++
+ "output. If ⟨n⟩ is omitted level 2 is assumed."
+ , flagType = DynamicFlag
+ }
]