Skip to content

Conversation

@Flamefire
Copy link
Contributor

Inspecting the function I see some corner cases that could yield wrong values and/or overflow.

What I suspect:

  • There is an off-by-one error in the buffer size which causes early truncation of the significant
  • The exponent might overflow if it is too large. By using a type with at least 20bits this likely does not happen in practice, so I guess that should be enforced.
  • However for large strings the exponent might still overflow or even e.g. leading_zero_powers or extra_zeroes might already

I came up with some tests that should exercise the corner cases. Please check if they make sense so far before I go into more details

@Flamefire Flamefire changed the title Test range Test corner cases of parser Dec 28, 2024
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

Successfully merging this pull request may close these issues.

1 participant