summaryrefslogtreecommitdiff
path: root/mi
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2017-06-28 03:24:57 -0700
committerOri Bernstein <ori@markovcorp.com>2017-06-28 10:59:54 -0700
commit567766b0cb773c76a9ec0d16246bd27b4a46b851 (patch)
tree47da5cff2284f691083c6b8445ded0047a174e85 /mi
parent6f5af8562ed5547ddaeb15ba7ed4a334318ca53f (diff)
downloadmc-567766b0cb773c76a9ec0d16246bd27b4a46b851.tar.gz
Remove unused memb from Trait and rename funcs -> proto
These are prototype declarations that must be implemented by the impl (not necessarily functions), so proto seems like a better name.
Diffstat (limited to 'mi')
-rw-r--r--mi/flatten.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/mi/flatten.c b/mi/flatten.c
index d79ceb3..0733a12 100644
--- a/mi/flatten.c
+++ b/mi/flatten.c
@@ -751,10 +751,10 @@ static Node *itertraitfn(Srcloc loc, Trait *tr, char *fn, Type *ty)
char *name;
size_t i;
- for (i = 0; i < tr->nfuncs; i++) {
- name = declname(tr->funcs[i]);
+ for (i = 0; i < tr->nproto; i++) {
+ name = declname(tr->proto[i]);
if (!strcmp(fn, name)) {
- proto = tr->funcs[i];
+ proto = tr->proto[i];
dcl = htget(proto->decl.impls, ty);
var = mkexpr(loc, Ovar, dcl->decl.name, NULL);
var->expr.type = dcl->decl.type;