Format$ now prints the expected number of decimal digits when using exponential format.
[INTERPRETER] * BUG: Format$ now prints the expected number of decimal digits when using exponential format.
This commit is contained in:
parent
dd53172230
commit
a6a8d04b99
1 changed files with 6 additions and 1 deletions
|
@ -1015,7 +1015,12 @@ _FORMAT:
|
|||
{
|
||||
number_mant = frexp10(fabs(number), &number_exp);
|
||||
ndigit = after;
|
||||
if (!exposant) ndigit += number_exp;
|
||||
|
||||
if (!exposant)
|
||||
ndigit += number_exp;
|
||||
else
|
||||
ndigit++;
|
||||
|
||||
ndigit = MinMax(ndigit, 0, MAX_FLOAT_DIGIT);
|
||||
//fprintf(stderr, "number_mant = %.24g number_exp = %d ndigit = %d\n", number_mant, number_exp, ndigit);
|
||||
|
||||
|
|
Loading…
Reference in a new issue