summaryrefslogtreecommitdiff
path: root/parse/gram.y
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2017-08-20 17:49:01 -0700
committerOri Bernstein <ori@eigenstate.org>2017-08-20 17:49:01 -0700
commit6e4bf0cdecce71d9a839c1e7f6a42409c2f9d961 (patch)
tree04118201b212982737c1a81988f20fce9bde58b2 /parse/gram.y
parentdfed30d87b4f9dbae24b16ddd32ea0be69a5d602 (diff)
downloadmc-6e4bf0cdecce71d9a839c1e7f6a42409c2f9d961.tar.gz
Fix trait shit.
Diffstat (limited to 'parse/gram.y')
-rw-r--r--parse/gram.y4
1 files changed, 3 insertions, 1 deletions
diff --git a/parse/gram.y b/parse/gram.y
index 6198b49..424538e 100644
--- a/parse/gram.y
+++ b/parse/gram.y
@@ -1081,7 +1081,9 @@ static void addtrait(Type *t, char *str)
for (i = 0; i < ntraittab; i++) {
if (!strcmp(namestr(traittab[i]->name), str)) {
- settrait(t, traittab[i]);
+ if (!t->trneed)
+ t->trneed = mkbs();
+ bsput(t->trneed, i);
return;
}
}