diff options
author | Krzysztof Gogolewski <krzysztof.gogolewski@tweag.io> | 2021-06-28 23:20:37 +0200 |
---|---|---|
committer | Marge Bot <ben+marge-bot@smart-cactus.org> | 2021-07-27 21:35:17 -0400 |
commit | 9da20e3de5513ccccf8144c69f5e63dd4eaae6f4 (patch) | |
tree | 6572af17acbcf3ec43ac7fa2c6989f8edc92535e /compiler/GHC/HsToCore | |
parent | cab890f73b534375135d372ba9f7eb8f5f523e16 (diff) | |
download | haskell-9da20e3de5513ccccf8144c69f5e63dd4eaae6f4.tar.gz |
Don't abort on representation polymorphism check
This is reverting a change introduced in linear types commit 40fa237e1da.
Previously, we had to abort early, but thanks to later changes,
this is no longer needed.
There's no test, but the behavior should be better.
The plan is to remove levity polymorphism checking in the desugarer anyway.
Diffstat (limited to 'compiler/GHC/HsToCore')
-rw-r--r-- | compiler/GHC/HsToCore/Monad.hs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/GHC/HsToCore/Monad.hs b/compiler/GHC/HsToCore/Monad.hs index 6fd3ef10c4..9ae0b78418 100644 --- a/compiler/GHC/HsToCore/Monad.hs +++ b/compiler/GHC/HsToCore/Monad.hs @@ -600,7 +600,7 @@ discardWarningsDs thing_inside dsNoLevPoly :: Type -> LevityCheckProvenance -> DsM () -- See Note [Representation polymorphism checking] dsNoLevPoly ty provenance = - checkForLevPolyX (\ty -> failWithDs . DsLevityPolyInType ty) provenance ty + checkForLevPolyX (\ty -> diagnosticDs . DsLevityPolyInType ty) provenance ty -- | Check an expression for representation polymorphism, failing if it is -- representation-polymorphic. |