Do not cast to float where usual arithmetic conversions obviously
convert the cast's result to double. Such casts are ugly and may lose precision.
This commit is contained in:
parent
802f69b039
commit
7a99405942
14 changed files with 35 additions and 35 deletions
|
@ -191,7 +191,7 @@ prod_plane(int etus, int natnum, int *bp, int buildem)
|
|||
if (left > delta)
|
||||
left = delta;
|
||||
|
||||
leftp = ((float)left / 100.0);
|
||||
leftp = left / 100.0;
|
||||
memset(mvec, 0, sizeof(mvec));
|
||||
mvec[I_MILIT] = mil_needed = ldround(plp->pl_crew * leftp, 1);
|
||||
mvec[I_LCM] = lcm_needed = ldround(plp->pl_lcm * leftp, 1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue