diff options
author | Quentin Carbonneaux <quentin.carbonneaux@yale.edu> | 2016-03-17 13:41:12 -0400 |
---|---|---|
committer | Quentin Carbonneaux <quentin.carbonneaux@yale.edu> | 2016-03-17 13:41:12 -0400 |
commit | 240cfcd5cdda9301457867f9d26edcd0cf272b24 (patch) | |
tree | 83cf01d43ad41163c96c34f16f2d24a4e8f9eff9 /lisc/util.c | |
parent | 2889d44f24d8017f527f6f5aa1163065cc57e994 (diff) | |
download | roux-240cfcd5cdda9301457867f9d26edcd0cf272b24.tar.gz |
support return of structs
Diffstat (limited to 'lisc/util.c')
-rw-r--r-- | lisc/util.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lisc/util.c b/lisc/util.c index fc9884a..368a060 100644 --- a/lisc/util.c +++ b/lisc/util.c @@ -174,7 +174,7 @@ phicls(int t, Tmp *tmp /*, int c*/) } Ref -newtmp(char *prfx, Fn *fn) +newtmp(char *prfx, int k, Fn *fn) { static int n; int t; @@ -182,6 +182,7 @@ newtmp(char *prfx, Fn *fn) t = fn->ntmp++; vgrow(&fn->tmp, fn->ntmp); sprintf(fn->tmp[t].name, "%s%d", prfx, ++n); + fn->tmp[t].cls = k; fn->tmp[t].slot = -1; fn->tmp[t].nuse = +1; fn->tmp[t].ndef = +1; |