sparsetech/toml-scala

Can't parse float number expressed in scientific notation

SnipyJulmy opened this issue · 1 comments

Toml-scala can't parse number in floating point expressed in a scientific notation.

Example :

scala> import toml.Toml ; Toml.parse("poly = -45e12")
import toml.Toml
res4: Either[String,toml.Value.Tbl] = Right(Tbl(Map(poly -> Real(-4.5E13))))

scala> import toml.Toml ; Toml.parse("poly = -45.321e12")
import toml.Toml
res5: Either[String,toml.Value.Tbl] = Left(End:1:15 ..."e12")

Let me know if you need more from me.

Thanks for the bug report! We should also make sure that all other floating point examples from the TOML specification work as expected.