From 1fa52170bf579fc360517435d3af3e58bab370e6 Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Thu, 4 Aug 2022 20:46:42 -0700 Subject: [PATCH] expr: remove now unused 'disc' parameter from 'Exdisc_t.reff' --- lib/expr/exgram.h | 2 +- lib/expr/exparse.y | 2 +- lib/expr/expr.h | 2 +- lib/expr/extoken.c | 2 +- lib/gvpr/compile.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/expr/exgram.h b/lib/expr/exgram.h index d3ddbc914..85e58ab09 100644 --- a/lib/expr/exgram.h +++ b/lib/expr/exgram.h @@ -399,7 +399,7 @@ static Exnode_t *makeVar(Expr_t * prog, Exid_t * s, Exnode_t * idx, else if (expr.program->disc->reff) (*expr.program->disc->reff) (prog, nn, nn->data.variable.symbol, refs, - NULL, EX_SCALAR, prog->disc); + NULL, EX_SCALAR); return nn; } diff --git a/lib/expr/exparse.y b/lib/expr/exparse.y index b448eeb8f..09a9126ab 100644 --- a/lib/expr/exparse.y +++ b/lib/expr/exparse.y @@ -1009,7 +1009,7 @@ constant : CONSTANT if (!expr.program->disc->reff) exerror("%s: identifier references not supported", $1->name); else - $$->data.constant.value = (*expr.program->disc->reff)(expr.program, $$, $1, NULL, NULL, EX_SCALAR, expr.program->disc); + $$->data.constant.value = (*expr.program->disc->reff)(expr.program, $$, $1, NULL, NULL, EX_SCALAR); } | FLOATING { diff --git a/lib/expr/expr.h b/lib/expr/expr.h index bf0ceed4e..933299c20 100644 --- a/lib/expr/expr.h +++ b/lib/expr/expr.h @@ -215,7 +215,7 @@ struct Exdisc_s /* discipline */ Exerror_f errorf; /* error function */ Extype_t (*getf)(Expr_t*, Exnode_t*, Exid_t*, Exref_t*, void*, int, Exdisc_t*); /* get value function */ - Extype_t (*reff)(Expr_t*, Exnode_t*, Exid_t*, Exref_t*, char*, int, Exdisc_t*); + Extype_t (*reff)(Expr_t*, Exnode_t*, Exid_t*, Exref_t*, char*, int); /* reference value function */ int (*setf)(Expr_t*, Exnode_t*, Exid_t*, Exref_t*, void*, int, Extype_t, Exdisc_t*); /* set value function */ diff --git a/lib/expr/extoken.c b/lib/expr/extoken.c index ed0ba6d6d..8864b1e24 100644 --- a/lib/expr/extoken.c +++ b/lib/expr/extoken.c @@ -859,7 +859,7 @@ extoken_fn(Expr_t* ex) } break; } - (*ex->disc->reff)(ex, NULL, ex_lval.id, NULL, exstash(ex->tmp, NULL), 0, ex->disc); + (*ex->disc->reff)(ex, NULL, ex_lval.id, NULL, exstash(ex->tmp, NULL), 0); /*..INDENT*/ } diff --git a/lib/gvpr/compile.c b/lib/gvpr/compile.c index c07594d36..303bc34d4 100644 --- a/lib/gvpr/compile.c +++ b/lib/gvpr/compile.c @@ -1809,7 +1809,7 @@ static tctype typeChkExp(Exref_t * ref, Exid_t * sym) */ static Extype_t refval(Expr_t * pgm, Exnode_t * node, Exid_t * sym, Exref_t * ref, - char *str, int elt, Exdisc_t * disc) + char *str, int elt) { (void)str; (void)elt; -- 2.40.0