diff options
Diffstat (limited to 'expr.c')
-rw-r--r-- | expr.c | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -1107,6 +1107,7 @@ static struct expr * castexpr(struct scope *s) { struct type *t, *ct; + struct decl *d; enum typequal tq; struct expr *r, *e, **end; @@ -1126,8 +1127,10 @@ castexpr(struct scope *s) e = mkexpr(EXPRCOMPOUND, t, NULL); e->qual = tq; e->lvalue = true; + d = mkdecl(NULL, DECLOBJECT, t, tq, LINKNONE); + d->u.obj.storage = s == &filescope ? SDSTATIC : SDAUTO; + e->u.compound.decl = d; e->u.compound.init = parseinit(s, t); - e->u.compound.storage = s == &filescope ? SDSTATIC : SDAUTO; e = postfixexpr(s, decay(e)); goto done; } |