summaryrefslogtreecommitdiff
path: root/toc.c
diff options
context:
space:
mode:
authorLeo Tenenbaum <pommicket@gmail.com>2019-11-24 15:00:37 -0500
committerLeo Tenenbaum <pommicket@gmail.com>2019-11-24 15:00:37 -0500
commitdf32f79671e392129147d56dbd87c4639bf8b901 (patch)
treedc11e70213b3882102275730410c5e82a6b101dc /toc.c
parent63c942c4bdf7d90f47e7671a2b88ec7b8fd81e21 (diff)
started to get fn(t @ Type, x: t) to work
Diffstat (limited to 'toc.c')
-rw-r--r--toc.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/toc.c b/toc.c
index 9577888..05697a3 100644
--- a/toc.c
+++ b/toc.c
@@ -15,6 +15,7 @@
static Type *type_user_underlying(Type *t) {
assert(t->kind == TYPE_USER);
+ assert(t->flags & TYPE_IS_RESOLVED);
Declaration *d = t->user.decl;
assert(d->flags & DECL_FOUND_VAL);
return (d->type.kind == TYPE_TUPLE ? d->val.tuple[t->user.index] : d->val).type;