diff options
author | Krzysztof Gogolewski <krzysztof.gogolewski@tweag.io> | 2021-09-24 13:21:04 +0200 |
---|---|---|
committer | Krzysztof Gogolewski <krzysztof.gogolewski@tweag.io> | 2021-09-24 14:14:11 +0200 |
commit | b094d4d05b5386d85a32b0c4e941f711f088230c (patch) | |
tree | 5eea7b9e5e06d00ac312c31271fa710e3110d21c | |
parent | d098eb993b4c0fb7c1da7643506832896c7c9861 (diff) | |
download | haskell-wip/T20200-agda-test.tar.gz |
Revert "Convert lookupIdSubst panic back to a warning (#20200)"wip/T20200-agda-test
This reverts commit f3892b5f57b5a75c20eb12a45575a15b2a3dfd3f.
-rw-r--r-- | compiler/GHC/Core/Subst.hs | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/compiler/GHC/Core/Subst.hs b/compiler/GHC/Core/Subst.hs index 83e91ad21a..f05888fddc 100644 --- a/compiler/GHC/Core/Subst.hs +++ b/compiler/GHC/Core/Subst.hs @@ -61,7 +61,6 @@ import GHC.Types.Unique.Supply import GHC.Builtin.Names import GHC.Data.Maybe -import GHC.Utils.Trace import GHC.Utils.Misc import GHC.Utils.Outputable import GHC.Utils.Panic @@ -256,10 +255,9 @@ lookupIdSubst s@(Subst in_scope ids _ _) v | Just e <- lookupVarEnv ids v = e | Just v' <- lookupInScope in_scope v = Var v' -- Vital! See Note [Extending the Subst] - -- See #20200 - | otherwise = warnPprTrace True (text "GHC.Core.Subst.lookupIdSubst" <+> ppr v - $$ ppr s) $ - Var v + -- If v isn't in the InScopeSet, we panic, because + -- it's a bad bug and we reallly want to know + | otherwise = pprPanic "lookupIdSubst" (ppr v $$ ppr s) delBndr :: Subst -> Var -> Subst delBndr (Subst in_scope ids tvs cvs) v |