mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2025-01-18 23:11:38 +00:00
Partially implement casts.
This commit is contained in:
parent
bf626c9e00
commit
a79b6f0a6c
1 changed files with 12 additions and 2 deletions
|
@ -421,6 +421,17 @@ expr_expr (sblock_t *sblock, expr_t *e, operand_t **op)
|
||||||
return sblock;
|
return sblock;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static sblock_t *
|
||||||
|
expr_cast (sblock_t *sblock, expr_t *e, operand_t **op)
|
||||||
|
{
|
||||||
|
if (!*op) {
|
||||||
|
(*op) = new_operand (op_temp);
|
||||||
|
(*op)->type = e->e.expr.type->type;
|
||||||
|
}
|
||||||
|
sblock = statement_subexpr (sblock, e->e.expr.e1, op);
|
||||||
|
return sblock;
|
||||||
|
}
|
||||||
|
|
||||||
static sblock_t *
|
static sblock_t *
|
||||||
expr_uexpr (sblock_t *sblock, expr_t *e, operand_t **op)
|
expr_uexpr (sblock_t *sblock, expr_t *e, operand_t **op)
|
||||||
{
|
{
|
||||||
|
@ -432,8 +443,7 @@ expr_uexpr (sblock_t *sblock, expr_t *e, operand_t **op)
|
||||||
sblock = expr_deref (sblock, e, op);
|
sblock = expr_deref (sblock, e, op);
|
||||||
break;
|
break;
|
||||||
case 'C':
|
case 'C':
|
||||||
//FIXME
|
sblock = expr_cast (sblock, e, op);
|
||||||
sblock = statement_subexpr (sblock, e->e.expr.e1, op);
|
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
;
|
;
|
||||||
|
|
Loading…
Reference in a new issue