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

Indicate the current or next argument on signature help #850

Merged
merged 2 commits into from
Jul 11, 2023

Conversation

tk0miya
Copy link
Contributor

@tk0miya tk0miya commented Jul 8, 2023

preview

def active_parameter_for(method_type, argument_nodes, last_argument_nodes, node)
return unless method_type

positionals = method_type.type.required_positionals.size + method_type.type.optional_positionals.size + (method_type.type.rest_positionals ? 1 : 0) + method_type.type.trailing_positionals.size
Copy link
Contributor Author

Choose a reason for hiding this comment

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

Note: This patch did not take care of trailing_positionals because I don't know about it.

@soutaro soutaro added this to the Steep 1.5 milestone Jul 11, 2023
@soutaro soutaro enabled auto-merge July 11, 2023 00:51
@soutaro soutaro merged commit c8f5213 into soutaro:master Jul 11, 2023
20 checks passed
@tk0miya tk0miya deleted the signature_help_active_parameter branch July 11, 2023 02:00
@soutaro soutaro added the Released The PR is already included in a published release label Jul 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Released The PR is already included in a published release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants