summaryrefslogtreecommitdiff
path: root/compiler/GHC/Driver/Flags.hs
diff options
context:
space:
mode:
authorMatthew Pickering <matthewtpickering@gmail.com>2022-06-15 11:45:33 +0100
committerMatthew Pickering <matthewtpickering@gmail.com>2022-06-15 11:54:27 +0100
commit127e8cbb3529937b4c3e9ea762ae885d92de6d8d (patch)
treeb4e278a73f8e68eb76b4f04a6b969fc581af32c8 /compiler/GHC/Driver/Flags.hs
parentac83899dcb5931913699d191f2c46780483ed07e (diff)
downloadhaskell-wip/suppress-err-context.tar.gz
Add -fsuppress-error-contexts to disable printing error contexts in errorswip/suppress-err-context
In many development environments, the source span is the primary means of seeing what an error message relates to, and the In the expression: and In an equation for: clauses are not particularly relevant. However, they can grow to be quite long, which can make the message itself both feel overwhelming and interact badly with limited-space areas. It's simple to implement this flag so we might as well do it and give the user control about how they see their messages. Fixes #21722
Diffstat (limited to 'compiler/GHC/Driver/Flags.hs')
-rw-r--r--compiler/GHC/Driver/Flags.hs3
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler/GHC/Driver/Flags.hs b/compiler/GHC/Driver/Flags.hs
index 209e6d1776..b6d198789e 100644
--- a/compiler/GHC/Driver/Flags.hs
+++ b/compiler/GHC/Driver/Flags.hs
@@ -375,6 +375,9 @@ data GeneralFlag
| Opt_SuppressTimestamps -- ^ Suppress timestamps in dumps
| Opt_SuppressCoreSizes -- ^ Suppress per binding Core size stats in dumps
+ -- Error message suppression
+ | Opt_SuppressErrorContext
+
-- temporary flags
| Opt_AutoLinkPackages
| Opt_ImplicitImportQualified