Repository navigation
[release/11.0] Fix BigInteger hex overflow test on 64-bit runtimes - #138289
Open
github-actions[bot] wants to merge 1 commit into
Open
github-actions[bot] wants to merge 1 commit into
github-actions[bot] wants to merge 1 commit into
Conversation
`TryParse_VeryLargeNegativeNumber` sized its input for 32-bit limbs, so the input no longer overflowed on 64-bit runtimes after BigInteger switched to native-width limbs. Derive the hex digit count from the native limb width so the existing checks exercise the overflow boundary on both architectures. No product code changes. Resolves #138217 > [!NOTE] > This pull request description was drafted with GitHub Copilot. Co-authored-by: Copilot App <[email protected]>
|
Azure Pipelines: Successfully started running 3 pipeline(s). 12 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
|
Tagging subscribers to this area: @dotnet/area-system-numerics |
tannergooding
approved these changes
Nov 25, 2026
lewing
enabled auto-merge (squash)
November 25, 2026 17:35
This was referenced Nov 25, 2026
Open
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport of #138222 to release/11.0. Test-only; no product code changes.
/cc @lewing @tannergooding
TryParse_VeryLargeNegativeNumbersized its input for 32-bit limbs, so after BigInteger switched to native-width (nuint) limbs, which release/11.0 also has, the input no longer overflows on 64-bit runtimes. The fix derives the hex digit count fromnint.Size.Fixes #138217
Customer Impact
None; test-only.
Regression
No.
Testing
Clean cherry-pick, not compiled locally; PR CI builds System.Runtime.Numerics.Tests (the test itself is OuterLoop).
Risk
Low; test-only.