-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Parsing "+" or "-" to f32/f64 on nightly #29042
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Labels
regression-from-stable-to-beta
Performance or correctness regression from stable to beta.
Comments
Oh my, the float part is embarrassing. Preparing a fix right now. |
Thanks for taking a look @rkruppe! Looks like this is working as expected on stable and has leaked into beta/nightly, so tagging as such. |
Yes, this is a bug (not checking for empty strings in the right places) of the dec2flt code. The bug is also in beta, so the PR (which I'll file very soon) should probably be backported to beta. |
hanna-kruppe
pushed a commit
to hanna-kruppe/rust
that referenced
this issue
Oct 14, 2015
bors
added a commit
that referenced
this issue
Oct 15, 2015
brson
pushed a commit
to brson/rust
that referenced
this issue
Oct 16, 2015
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I tried this code:
I expected to see this happen: "Error: invalid float literal"
Instead, this happened: OK: 0
It seems the "leading +" and "leading -" is broken.
Further, with i32 and i64 is emits an error but IMO an incorrect one:
"cannot parse integer from empty string"
I would expect: "Invalid integer literal"
Meta
rustc --version --verbose
:rustc 1.5.0-nightly (81b3b27 2015-10-11)
binary: rustc
commit-hash: 81b3b27
commit-date: 2015-10-11
host: x86_64-unknown-linux-gnu
release: 1.5.0-nightly
The text was updated successfully, but these errors were encountered: