diff options
author | Alfredo Di Napoli <alfredo@well-typed.com> | 2021-04-19 14:29:18 +0200 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-05-26 16:03:15 -0400 |
commit | cdbce8fc22448837e53515946f16e9571e06f412 (patch) | |
tree | a07372a960e55eaeff036ed717272b47f821711b /compiler/GHC/Driver/Config.hs | |
parent | 2023b344a7567492881745609c494a9427dc8c30 (diff) | |
download | haskell-cdbce8fc22448837e53515946f16e9571e06f412.tar.gz |
Support new parser types in GHC
This commit converts the lexers and all the parser machinery to use the
new parser types and diagnostics infrastructure. Furthermore, it cleans
up the way the parser code was emitting hints.
As a result of this systematic approach, the test output of the
`InfixAppPatErr` and `T984` tests have been changed. Previously they
would emit a `SuggestMissingDo` hint, but this was not at all helpful in
resolving the error, and it was even confusing by just looking at the
original program that triggered the errors.
Update haddock submodule
Diffstat (limited to 'compiler/GHC/Driver/Config.hs')
-rw-r--r-- | compiler/GHC/Driver/Config.hs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/compiler/GHC/Driver/Config.hs b/compiler/GHC/Driver/Config.hs index cd3b165a65..7a96271403 100644 --- a/compiler/GHC/Driver/Config.hs +++ b/compiler/GHC/Driver/Config.hs @@ -15,6 +15,7 @@ import GHC.Core.SimpleOpt import GHC.Core.Coercion.Opt import GHC.Parser.Lexer import GHC.Runtime.Interpreter (BCOOpts(..)) +import GHC.Utils.Error (mkPlainMsgEnvelope) import GHCi.Message (EvalOpts(..)) import GHC.Conc (getNumProcessors) @@ -39,6 +40,7 @@ initParserOpts = mkParserOpts <$> warningFlags <*> extensionFlags + <*> mkPlainMsgEnvelope <*> safeImportsOn <*> gopt Opt_Haddock <*> gopt Opt_KeepRawTokenStream |