summaryrefslogtreecommitdiff
path: root/compiler/GHC/Types/Name/Shape.hs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/GHC/Types/Name/Shape.hs')
-rw-r--r--compiler/GHC/Types/Name/Shape.hs7
1 files changed, 3 insertions, 4 deletions
diff --git a/compiler/GHC/Types/Name/Shape.hs b/compiler/GHC/Types/Name/Shape.hs
index 456c1d6d24..c65124d51c 100644
--- a/compiler/GHC/Types/Name/Shape.hs
+++ b/compiler/GHC/Types/Name/Shape.hs
@@ -29,8 +29,7 @@ import GHC.Tc.Utils.Monad
import GHC.Iface.Env
import GHC.Utils.Outputable
-import GHC.Utils.Misc
-import GHC.Utils.Panic
+import GHC.Utils.Panic.Plain
import Control.Monad
@@ -268,11 +267,11 @@ uName flexi subst n1 n2
uHoleName :: ModuleName -> ShNameSubst -> Name {- hole name -} -> Name
-> Either SDoc ShNameSubst
uHoleName flexi subst h n =
- ASSERT( isHoleName h )
+ assert (isHoleName h) $
case lookupNameEnv subst h of
Just n' -> uName flexi subst n' n
-- Do a quick check if the other name is substituted.
Nothing | Just n' <- lookupNameEnv subst n ->
- ASSERT( isHoleName n ) uName flexi subst h n'
+ assert (isHoleName n) $ uName flexi subst h n'
| otherwise ->
Right (extendNameEnv subst h n)