aboutsummaryrefslogtreecommitdiff
path: root/stmt.c
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2022-05-09 13:22:45 -0700
committerMichael Forney <mforney@mforney.org>2022-05-11 11:15:56 -0700
commitd99805f26575a0e0a7323fdaf56daec7b1857eda (patch)
tree6c794bdca32cc91c87cf23e828fc8e375fb34971 /stmt.c
parentef3b6b33eba80b82ae3da1d8e322b531bfc99902 (diff)
expr: Implement type-checking for casts and assignments
Diffstat (limited to 'stmt.c')
-rw-r--r--stmt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/stmt.c b/stmt.c
index 244d2da..843852c 100644
--- a/stmt.c
+++ b/stmt.c
@@ -296,7 +296,7 @@ stmt(struct func *f, struct scope *s)
next();
t = functype(f);
if (t->base != &typevoid) {
- e = exprconvert(expr(s), t->base);
+ e = exprassign(expr(s), t->base);
v = funcexpr(f, e);
delexpr(e);
} else {