Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Index forwarded parameters #2540

Merged
merged 1 commit into from
Sep 12, 2024
Merged

Index forwarded parameters #2540

merged 1 commit into from
Sep 12, 2024

Conversation

vinistock
Copy link
Member

Motivation

Step towards #2363

To support showing the correct overload in signature help, we need a way of verifying that a method call arity matches the method declaration arity.

When reviewing all parameter types and how we would match the arities, we noticed that we were not indexing forwarding parameters at all, which we need to do for the sake of completeness and proper matching.

Implementation

Added a new class for the forwarding parameter and started handling it in the declaration listener. Notice that you can't name a forwarding parameter, so I added an override for initialize that forces the name to be ....

Automated Tests

Added tests.

@vinistock vinistock added enhancement New feature or request server This pull request should be included in the server gem's release notes labels Sep 11, 2024
@vinistock vinistock self-assigned this Sep 11, 2024
@vinistock vinistock requested a review from a team as a code owner September 11, 2024 18:32
@vinistock vinistock requested review from andyw8 and st0012 September 11, 2024 18:32
@vinistock vinistock merged commit 68719fd into main Sep 12, 2024
37 checks passed
@vinistock vinistock deleted the vs-index-forwarding-parameters branch September 12, 2024 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request server This pull request should be included in the server gem's release notes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants