diff options
author | Vladislav Zavialov <vlad.z.4096@gmail.com> | 2019-03-17 13:47:09 +0300 |
---|---|---|
committer | Vladislav Zavialov <vlad.z.4096@gmail.com> | 2019-03-17 14:56:19 +0300 |
commit | fd4009d80533803a4dee959015b96c1626e5ed88 (patch) | |
tree | f8261b50be739b9675ef710d890aa58d0ced5a98 /compiler/deSugar/Check.hs | |
parent | cb61371e3260e07be724a04b72a935133f66b514 (diff) | |
download | haskell-wip/pat-builder.tar.gz |
PatBuilder - WIPwip/pat-builder
Diffstat (limited to 'compiler/deSugar/Check.hs')
-rw-r--r-- | compiler/deSugar/Check.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/compiler/deSugar/Check.hs b/compiler/deSugar/Check.hs index db3a501fcf..8522cf4e26 100644 --- a/compiler/deSugar/Check.hs +++ b/compiler/deSugar/Check.hs @@ -915,12 +915,12 @@ truePattern = nullaryConPattern (RealDataCon trueDataCon) -- | A fake guard pattern (True <- _) used to represent cases we cannot handle fake_pat :: Pattern fake_pat = PmGrd { pm_grd_pv = [truePattern] - , pm_grd_expr = PmExprOther (EWildPat noExt) } + , pm_grd_expr = PmExprFake } {-# INLINE fake_pat #-} -- | Check whether a guard pattern is generated by the checker (unhandled) isFakeGuard :: [Pattern] -> PmExpr -> Bool -isFakeGuard [PmCon { pm_con_con = RealDataCon c }] (PmExprOther (EWildPat _)) +isFakeGuard [PmCon { pm_con_con = RealDataCon c }] PmExprFake | c == trueDataCon = True | otherwise = False isFakeGuard _pats _e = False |