extendSubst (Subst in_scope ids tvs) tv (Type ty)
= ASSERT( isTyVar tv ) Subst in_scope ids (extendVarEnv tvs tv ty)
extendSubst (Subst in_scope ids tvs) id expr
= ASSERT( isId id ) Subst in_scope (extendVarEnv ids id expr) tvs
lookupIdSubst :: Subst -> Id -> CoreExpr
extendSubst (Subst in_scope ids tvs) tv (Type ty)
= ASSERT( isTyVar tv ) Subst in_scope ids (extendVarEnv tvs tv ty)
extendSubst (Subst in_scope ids tvs) id expr
= ASSERT( isId id ) Subst in_scope (extendVarEnv ids id expr) tvs
lookupIdSubst :: Subst -> Id -> CoreExpr