[erlang-questions] Bug? Pretty-printing floating point values

Christian S chsu79@REDACTED
Wed Nov 21 16:12:45 CET 2007


Doesn't look like the number of significant digits when read are stored.

I wouldn't call it a bug. It is how floating point numbers work.
They're very exact with fractions that are a sum of limited numbers of
negative powers of two though.

2007/11/21, Joel Reymont <joelr1@REDACTED>:
> I see {float,1,6.30000} in the AST but 6.29999999999999982236 is
> pretty-printed.
>
> Is this a bug? Is there a workaround?



More information about the erlang-questions mailing list