Skip to content
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

Double.parseDouble("0e555") != FastDoubleParser.parseDouble("0e555") #6

Closed
fmeum opened this issue Mar 23, 2021 · 1 comment
Closed

Comments

@fmeum
Copy link

fmeum commented Mar 23, 2021

Double.parseDouble and FastDoubleParser.parseDouble return different results for the string "0e555":

Double.parseDouble("0e555"): 0.0
FastDoubleParser.parseDouble("0e555"): Infinity

Edit: I believe that is caused by the special case at

return negative ? Double.NEGATIVE_INFINITY : Double.POSITIVE_INFINITY;
, which does not handle the even more special case of the mantissa being 0.

@wrandelshofer
Copy link
Owner

Thank you very much. I made a fix in revision d8c9aa0 .

@fmeum fmeum closed this as completed Mar 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants