commit cee718c7067643bb4a9c88523f24959e02e80d92
parent adc5dcec8156fcb56786032855f00e0a176b9085
Author: Drew DeVault <sir@cmpwn.com>
Date: Thu, 12 Aug 2021 08:02:37 +0200
gen: dealias call lvalue type
Signed-off-by: Drew DeVault <sir@cmpwn.com>
Diffstat:
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/gen.c b/src/gen.c
@@ -884,7 +884,7 @@ gen_expr_call(struct gen_context *ctx, const struct expression *expr)
struct gen_value lvalue = gen_expr(ctx, expr->call.lvalue);
lvalue = gen_autoderef(ctx, lvalue);
- const struct type *rtype = lvalue.type;
+ const struct type *rtype = type_dealias(lvalue.type);
assert(rtype->storage == STORAGE_FUNCTION);
if (rtype->func.flags & FN_NORETURN) {