Skip to content

Support anonymous rest and keyword argument forwarding#336

Merged
mame merged 1 commit into
ruby:masterfrom
sinsoku:fix-anonymous-args-support
Aug 22, 2025
Merged

Support anonymous rest and keyword argument forwarding#336
mame merged 1 commit into
ruby:masterfrom
sinsoku:fix-anonymous-args-support

Conversation

@sinsoku

@sinsoku sinsoku commented Aug 21, 2025

Copy link
Copy Markdown
Collaborator
  • Fix NoMethodError when using anonymous rest (*) and keyword (**) forwarding
  • Extract Hash value types for RBS keyword parameters (Hash[K, V] → V)
  • Add proper type inference for anonymous argument scenarios

This enables method calls like foo(*) and foo(**) to work correctly and ensures RBS output shows the actual value types for keyword parameters rather than the full Hash type.

- Fix NoMethodError when using anonymous rest (*) and keyword (**) forwarding
- Extract Hash value types for RBS keyword parameters (Hash[K, V] → V)
- Add proper type inference for anonymous argument scenarios

This enables method calls like foo(*) and foo(**) to work correctly
and ensures RBS output shows the actual value types for keyword parameters
rather than the full Hash type.
@mame mame merged commit c10b0a9 into ruby:master Aug 22, 2025
7 checks passed
@mame

mame commented Aug 22, 2025

Copy link
Copy Markdown
Member

This looks simple and good, thanks!

@sinsoku sinsoku deleted the fix-anonymous-args-support branch November 1, 2025 07:37
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.

2 participants