[commit: ghc] wip/gadtpm: Add a further check to isSatisfiable in process_vector (bf44187)

git at git.haskell.org git at git.haskell.org
Tue Feb 10 13:22:31 UTC 2015


Repository : ssh://git@git.haskell.org/ghc

On branch  : wip/gadtpm
Link       : http://ghc.haskell.org/trac/ghc/changeset/bf44187c8ef982e876d8408f9df028f0130f7016/ghc

>---------------------------------------------------------------

commit bf44187c8ef982e876d8408f9df028f0130f7016
Author: Simon Peyton Jones <simonpj at microsoft.com>
Date:   Tue Feb 10 13:24:17 2015 +0000

    Add a further check to isSatisfiable in process_vector


>---------------------------------------------------------------

bf44187c8ef982e876d8408f9df028f0130f7016
 compiler/deSugar/Check.hs | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/compiler/deSugar/Check.hs b/compiler/deSugar/Check.hs
index a64ba89..324deb2 100644
--- a/compiler/deSugar/Check.hs
+++ b/compiler/deSugar/Check.hs
@@ -537,7 +537,8 @@ process_vector uncovered clause = do
   forces     <- anyBagM (\uvec -> alg_forces    uvec clause) uncovered
   covers     <- anyBagM (\uvec -> alg_covers    uvec clause) uncovered
   uncovered' <- mapBagM (\uvec -> alg_uncovered uvec clause) uncovered
-  return (covers, concatBag uncovered', forces)
+  uncovered'' <- filterBagM (\(delta,_) -> isSatisfiable delta) (concatBag uncovered')
+  return (covers, uncovered'', forces)
 
 -- | External interface. Takes:
 --   * The types of the arguments



More information about the ghc-commits mailing list