Skip to content

Use rb_len_t for the length of the winsize array - #176

Merged
hsbt merged 1 commit into
masterfrom
claude/cool-poitras-254c47
Oct 13, 2026
Merged

hsbt merged 1 commit into
masterfrom
claude/cool-poitras-254c47

Conversation

@hsbt

@hsbt hsbt commented Oct 10, 2026

Copy link
Copy Markdown
Member

Ruby master added rb_len_t as the type for lengths and indices of objects such as Array and String. IO#winsize= still keeps the length of its argument array in a long and formats it with %ld, so this switches both to rb_len_t and PRIdLEN.

On Rubies without rb_len_t, a fallback guarded by HAVE_RB_LEN_T defines them as long and "ld", so the behavior does not change there.

https://bugs.ruby-lang.org/issues/22400

Generated with Claude Code

Fall back to long when the Ruby headers do not provide rb_len_t, so nothing changes on the existing Rubies.

https://bugs.ruby-lang.org/issues/22400

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@hsbt
hsbt merged commit 8560a30 into master Oct 13, 2026
72 checks passed
@hsbt
hsbt deleted the claude/cool-poitras-254c47 branch October 13, 2026 00:00
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