mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-23 04:42:32 +00:00
fix a real oopsie with if (const)
This commit is contained in:
parent
9a97ee400b
commit
bb4e9de0db
1 changed files with 4 additions and 4 deletions
|
@ -1515,7 +1515,7 @@ convert_bool (expr_t *e, int block)
|
|||
if (e->type == ex_uexpr && e->e.expr.op == '!') {
|
||||
e = convert_bool (e->e.expr.e1, 0);
|
||||
if (e->type == ex_error)
|
||||
return e;
|
||||
return e;
|
||||
e = unary_expr ('!', e);
|
||||
}
|
||||
if (e->type != ex_bool) {
|
||||
|
@ -1523,11 +1523,11 @@ convert_bool (expr_t *e, int block)
|
|||
if (e->type == ex_error)
|
||||
return e;
|
||||
if (e->type == ex_integer) {
|
||||
e = new_unary_expr ('g', 0);
|
||||
b = new_unary_expr ('g', 0);
|
||||
if (e->e.integer_val)
|
||||
e = new_bool_expr (make_list (e), 0, e);
|
||||
e = new_bool_expr (make_list (b), 0, b);
|
||||
else
|
||||
e = new_bool_expr (0, make_list (e), e);
|
||||
e = new_bool_expr (0, make_list (b), b);
|
||||
} else {
|
||||
b = new_block_expr ();
|
||||
append_expr (b, new_binary_expr ('i', e, 0));
|
||||
|
|
Loading…
Reference in a new issue