Commit Graph

10 Commits

Author SHA1 Message Date
Mazdak Farrokhzad dbfbadeac4 libcore: deny more... 2019-04-19 01:37:12 +02:00
Alexander Regueiro 8629fd3e4e Improvements to comments in libstd, libcore, liballoc. 2019-03-11 02:25:44 +00:00
Alexander Regueiro 99ed06eb88 libs: doc comments 2019-02-10 23:57:25 +00:00
Mark Rousskov 2a663555dd Remove licenses 2018-12-25 21:08:33 -07:00
ljedrz d46dca66c9 Remove redundant field names in structs 2018-08-04 14:58:20 +02:00
varkor c0e87f13a4 Make ".e0" not parse as 0.0
This forces floats to have either a digit before the separating point, or after. Thus ".e0" is invalid like ".", when using `parse()`.
2018-02-19 14:53:30 +00:00
Jeffrey Seyfried e2ad3be178 Use #[prelude_import] in libcore. 2016-08-24 22:12:23 +00:00
Toby Scrace 33f3c52d32 Make float parsing "." return Err
This makes both of the following return Err:

    ".".parse::<f32>()
    ".".parse::<f64>()

This is a [breaking-change], which the libs team have classified as a
bug fix.
2016-01-04 18:23:33 +00:00
Robin Kruppe 71dcd7f70c Reject "+" and "-" when parsing floats.
Fixes #29042
2015-10-14 19:55:59 +02:00
Robin Kruppe ba792a4baa Accurate decimal-to-float parsing routines.
This commit primarily adds implementations of the algorithms from William
Clinger's paper "How to Read Floating Point Numbers Accurately". It also
includes a lot of infrastructure necessary for those algorithms, and some
unit tests.

Since these algorithms reject a few (extreme) inputs that were previously
accepted, this could be seen as a [breaking-change]
2015-08-08 17:15:31 +02:00