summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--parse/type.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/parse/type.c b/parse/type.c
index 8674d8c..1606269 100644
--- a/parse/type.c
+++ b/parse/type.c
@@ -236,8 +236,8 @@ mktygeneric(Srcloc loc, Node *name, Type **param, size_t nparam, Type *base)
bindtype(t->env, param[i]);
if (!base->env)
base->env = t->env;
- else
- assert(base->env->super == t->env);
+ else
+ assert(base->env->super == t->env || base->narg > 0);
return t;
}