mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-10 23:32:09 +00:00
Make gcc accept the bitwise-boolean magic
Forgot to compile check...
This commit is contained in:
parent
9d2d33fa50
commit
32c21ec559
1 changed files with 1 additions and 1 deletions
|
@ -1445,7 +1445,7 @@ op_call:
|
|||
// as division: -5 % 3 = -2, so need to add b (3 here)
|
||||
// if c's sign is incorrect, but only if c is non-zero
|
||||
int mask = (a ^ b) >> 31;
|
||||
mask &= ~!!c + 1;
|
||||
mask &= ~(!!c + 0) + 1; // +0 to convert bool to int (gcc)
|
||||
OPC.integer_var = c + (mask & b);
|
||||
}
|
||||
break;
|
||||
|
|
Loading…
Reference in a new issue