• Paul Eggert's avatar
    Improve (format "%g" bignum) precision · d4586b7a
    Paul Eggert authored
    * src/editfns.c (styled_format): When formatting bignums with
    floating-point conversions like %g, use long double if that
    would lose less information than double, which is what the
    code was already doing for fixnums.  On Fedora 28 x86-64, for
    example, (format "%.100g" (1- (ash 1 64))) now yields
    "18446744073709551615" instead of the numerically incorrect
    "18446744073709549568".  Also, fix a stray INTEGERP that
    can just be FIXNUMP, since bignums are not possible there.
    d4586b7a
editfns.c 176 KB