Skip to content

Update randint_untyped to reuse randint implementation - #176

Merged
ndgrigorian merged 5 commits into
masterfrom
update_randint_untyped
Sep 28, 2026
Merged

ndgrigorian merged 5 commits into
masterfrom
update_randint_untyped

Conversation

@vlad-perevezentsev

Copy link
Copy Markdown
Collaborator

This PR updates the randint_untyped implementation to reuse randint, adding

  • support for array_like (broadcastable) low/high bounds
  • support for bounds outside the C long range, which used to raise OverflowError for e.g. randint_untyped(0, 2**40) on Windows
  • shared validation so bad bounds report the same errors as randint

The generated values and the int32/int64 result type selection are unchanged.

It also removes irk_discrete_uniform_vec and irk_discrete_uniform_long_vec, left without callers by the change above.

ndgrigorian
ndgrigorian previously approved these changes Sep 24, 2026

@ndgrigorian ndgrigorian left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For the changes only in this PR, this LGTM

@antonwolfy antonwolfy added this to the 1.6.0 release milestone Sep 25, 2026
Base automatically changed from fix-scalar-full-range-brng to master September 28, 2026 19:00
@ndgrigorian
ndgrigorian dismissed their stale review September 28, 2026 19:00

The base branch was changed.

@ndgrigorian
ndgrigorian merged commit 598ea2d into master Sep 28, 2026
156 of 157 checks passed
@ndgrigorian
ndgrigorian deleted the update_randint_untyped branch September 28, 2026 20:38
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.

3 participants