-
Notifications
You must be signed in to change notification settings - Fork 1.9k
fix: Panic while rendering function type hint with impl trait arg #17832
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
Conversation
| let (fn_params, other) = | ||
| parameters.split_at(self_param as usize + type_ + const_ + lifetime); | ||
| let (_impl, parent_params) = other.split_at(impl_); | ||
| let (fn_params, parent_params) = parameters.split_at(without_impl + impl_); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
as generic_args is self + type params + const params + lifetimes + hidden generic with impl trait args, we should include impl to generate generic_args_sans_defaults
| let fn_params = | ||
| generic_args_sans_defaults(f, Some(generic_def_id), fn_params); | ||
| &generic_args_sans_defaults(f, Some(generic_def_id), fn_params) | ||
| [0..without_impl]; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
And we exclude impl trait things here
|
Thanks! |
|
☀️ Test successful - checks-actions |
Fixes #17811