mirror of
https://github.com/netwide-assembler/nasm.git
synced 2025-07-24 10:25:42 -04:00
float.c: correct the exponent
We would accidentally produce an exponent which was exactly +1 from the correct one.
This commit is contained in:
parent
b8e604eb5d
commit
cdb227fa71
2
float.c
2
float.c
@ -376,7 +376,7 @@ static int to_float(char *str, int32_t sign, uint8_t *result,
|
|||||||
/*
|
/*
|
||||||
* Normalised.
|
* Normalised.
|
||||||
*/
|
*/
|
||||||
exponent += expmax;
|
exponent += expmax-1;
|
||||||
ieee_shr(mant, fmt->exponent);
|
ieee_shr(mant, fmt->exponent);
|
||||||
ieee_round(mant, fmt->words);
|
ieee_round(mant, fmt->words);
|
||||||
/* did we scale up by one? */
|
/* did we scale up by one? */
|
||||||
|
Loading…
x
Reference in New Issue
Block a user