[commit: ghc] master: Turn on MonadFail desugaring by default (aab8656)
git at git.haskell.org
git at git.haskell.org
Tue Aug 7 19:57:22 UTC 2018
Repository : ssh://git@git.haskell.org/ghc
On branch : master
Link : http://ghc.haskell.org/trac/ghc/changeset/aab8656ba0561e56048a1222c396d2d117aca5a7/ghc
>---------------------------------------------------------------
commit aab8656ba0561e56048a1222c396d2d117aca5a7
Author: Herbert Valerio Riedel <hvr at gnu.org>
Date: Mon Aug 6 12:53:06 2018 -0400
Turn on MonadFail desugaring by default
Summary:
This contains two commits:
----
Make GHC's code-base compatible w/ `MonadFail`
There were a couple of use-sites which implicitly used pattern-matches
in `do`-notation even though the underlying `Monad` didn't explicitly
support `fail`
This refactoring turns those use-sites into explicit case
discrimations and adds an `MonadFail` instance for `UniqSM`
(`UniqSM` was the worst offender so this has been postponed for a
follow-up refactoring)
---
Turn on MonadFail desugaring by default
This finally implements the phase scheduled for GHC 8.6 according to
https://prime.haskell.org/wiki/Libraries/Proposals/MonadFail#Transitionalstrategy
This also preserves some tests that assumed MonadFail desugaring to be
active; all ghc boot libs were already made compatible with this
`MonadFail` long ago, so no changes were needed there.
Test Plan: Locally performed ./validate --fast
Reviewers: bgamari, simonmar, jrtc27, RyanGlScott
Reviewed By: bgamari
Subscribers: bgamari, RyanGlScott, rwbarton, thomie, carter
Differential Revision: https://phabricator.haskell.org/D5028
>---------------------------------------------------------------
aab8656ba0561e56048a1222c396d2d117aca5a7
compiler/basicTypes/UniqSupply.hs | 6 ++++
compiler/codeGen/StgCmmCon.hs | 6 ++--
compiler/codeGen/StgCmmMonad.hs | 11 +++++++-
compiler/codeGen/StgCmmPrim.hs | 29 +++++++++-----------
compiler/coreSyn/MkCore.hs | 3 +-
compiler/deSugar/Coverage.hs | 8 ++++--
compiler/ghci/ByteCodeAsm.hs | 9 ++++--
compiler/ghci/RtClosureInspect.hs | 6 ++--
compiler/llvmGen/LlvmCodeGen/CodeGen.hs | 32 ++++++++++++++++------
compiler/main/DynFlags.hs | 2 ++
compiler/main/InteractiveEval.hs | 6 +++-
compiler/nativeGen/SPARC/CodeGen.hs | 10 +++++--
compiler/rename/RnNames.hs | 6 +++-
compiler/typecheck/TcGenFunctor.hs | 25 ++++++++++-------
docs/users_guide/8.6.1-notes.rst | 5 ++++
docs/users_guide/glasgow_exts.rst | 9 +++---
ghc/GHCi/UI.hs | 9 ++++--
testsuite/tests/annotations/should_run/annrun01.hs | 3 +-
testsuite/tests/deSugar/should_run/dsrun010.hs | 2 ++
testsuite/tests/determinism/determ017/A.hs | 2 +-
testsuite/tests/monadfail/MonadFailWarnings.hs | 2 +-
.../tests/monadfail/MonadFailWarningsDisabled.hs | 5 ++++
testsuite/tests/rebindable/rebindable1.hs | 2 +-
testsuite/tests/simplCore/should_run/T3591.hs | 2 +-
.../tests/wcompat-warnings/WCompatWarningsNotOn.hs | 2 +-
.../tests/wcompat-warnings/WCompatWarningsOff.hs | 2 +-
.../tests/wcompat-warnings/WCompatWarningsOn.hs | 2 +-
.../tests/wcompat-warnings/WCompatWarningsOnOff.hs | 2 +-
28 files changed, 141 insertions(+), 67 deletions(-)
Diff suppressed because of size. To see it, use:
git diff-tree --root --patch-with-stat --no-color --find-copies-harder --ignore-space-at-eol --cc aab8656ba0561e56048a1222c396d2d117aca5a7
More information about the ghc-commits
mailing list