Skip to content

Prevent signed integer overflow while accumulating hexadecimal exponent#287

Open
Ramya-9353 wants to merge 1 commit into
google:masterfrom
Ramya-9353:fix/hex-exponent-overflow
Open

Prevent signed integer overflow while accumulating hexadecimal exponent#287
Ramya-9353 wants to merge 1 commit into
google:masterfrom
Ramya-9353:fix/hex-exponent-overflow

Conversation

@Ramya-9353

Copy link
Copy Markdown

Summary

Prevent signed integer overflow when parsing extremely long hexadecimal floating-point literals.

Why

The internal exponent accumulator can exceed the range of int while processing extremely long hexadecimal inputs, resulting in undefined behavior. This change eliminates that possibility while preserving the existing behavior for valid inputs.

@google-cla

google-cla Bot commented Jul 4, 2026

Copy link
Copy Markdown

Thanks for your pull request! It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).

View this failed invocation of the CLA check for more information.

For the most up to date status, view the checks section at the bottom of the pull request.

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