summaryrefslogtreecommitdiff
path: root/compiler/iface/IfaceEnv.lhs
diff options
context:
space:
mode:
authorsimonpj@microsoft.com <unknown>2008-10-03 13:53:34 +0000
committersimonpj@microsoft.com <unknown>2008-10-03 13:53:34 +0000
commit66579ff945831c5fc9a17c58c722ff01f2268d76 (patch)
treee0f632b523acf046e38d1cc67ea74a12f29a6993 /compiler/iface/IfaceEnv.lhs
parent766b34f81d81d009f1070e297756423fbadbd421 (diff)
downloadhaskell-66579ff945831c5fc9a17c58c722ff01f2268d76.tar.gz
Add ASSERTs to all calls of nameModule
nameModule fails on an InternalName. These ASSERTS tell you which call failed.
Diffstat (limited to 'compiler/iface/IfaceEnv.lhs')
-rw-r--r--compiler/iface/IfaceEnv.lhs3
1 files changed, 2 insertions, 1 deletions
diff --git a/compiler/iface/IfaceEnv.lhs b/compiler/iface/IfaceEnv.lhs
index 5dcab1e73e..20d7327cfe 100644
--- a/compiler/iface/IfaceEnv.lhs
+++ b/compiler/iface/IfaceEnv.lhs
@@ -212,7 +212,8 @@ lookupOrigNameCache nc mod occ -- The normal case
extendOrigNameCache :: OrigNameCache -> Name -> OrigNameCache
extendOrigNameCache nc name
- = extendNameCache nc (nameModule name) (nameOccName name) name
+ = ASSERT2( isExternalName name, ppr name )
+ extendNameCache nc (nameModule name) (nameOccName name) name
extendNameCache :: OrigNameCache -> Module -> OccName -> Name -> OrigNameCache
extendNameCache nc mod occ name