1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-06-22 19:44:10 +02:00

(ice-9 format): Fix scaling floats with leading zeros

This commit is contained in:
Timothy Sample 2021-10-19 02:50:51 +02:00 committed by Daniel Llorens
parent 98dff7a75e
commit c85724bd0a
2 changed files with 9 additions and 3 deletions

View file

@ -1359,10 +1359,10 @@
(else
(if (> left-zeros 0)
(if (<= left-zeros shift) ; shift always > 0 here
(format:fn-shiftleft shift) ; shift out 0s
(begin
(format:fn-shiftleft left-zeros)
(set! format:fn-dot (- shift left-zeros))))
(set! format:fn-dot (- shift left-zeros)))
(format:fn-shiftleft shift)) ; shift out 0s
(set! format:fn-dot (+ format:fn-dot shift))))))))
(let ((negexp ; expon format m.nnnEee