summaryrefslogtreecommitdiff
path: root/parse/specialize.c
diff options
context:
space:
mode:
authorOri Bernstein <ori@eigenstate.org>2018-01-02 22:14:43 -0800
committerOri Bernstein <ori@eigenstate.org>2018-01-11 22:16:11 -0800
commit9424339d8d453f5c559edd5d23549d662d1c9d8d (patch)
treefc725c32315c782b60eae6d48a1bb9171d3040b4 /parse/specialize.c
parente6967548eec255e4518b1cdff5955d4b333f103b (diff)
downloadmc-9424339d8d453f5c559edd5d23549d662d1c9d8d.tar.gz
Fix how we bind types.
Now we accept most valid programs, and reject most invalid ones.
Diffstat (limited to 'parse/specialize.c')
-rw-r--r--parse/specialize.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/parse/specialize.c b/parse/specialize.c
index 74af0e9..622a3f8 100644
--- a/parse/specialize.c
+++ b/parse/specialize.c
@@ -98,6 +98,9 @@ tyspecialize(Type *orig, Tysubst *tsmap, Htab *delayed, Htab *trbase)
ret = mktyvar(t->loc);
ret->trneed = bsdup(t->trneed);
substput(tsmap, t, ret);
+ tmp = htget(seqbase, t);
+ if (tmp)
+ htput(seqbase, ret, tmp);
break;
case Tygeneric:
var = mktyvar(t->loc);