-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
Make function pointers implement traits for up to 12 parameters #28560
Conversation
(12 was chosen to be consistent with what we do for tuples) Fixes rust-lang#28559
r? @aturon (rust_highfive has picked a reviewer for you, use r? to override) |
@bors: r+ |
📌 Commit 5f66c70 has been approved by |
(12 was chosen to be consistent with what we do for tuples) Fixes #28559
@Manishearth |
Functions with a large number of arguments being used in other structs are basically inevitable in bindings. |
It's always good to do a bit of investigation into what caused regressions if they do happen, and as @petrochenkov mentioned we did indeed cut these back to reduce the massive metadata size of libcore. The number chosen for tuples was completely arbitrary, so there's not real reason to match it for functions, and I would prefer to have only the bare minimum necessary to get things working until we find a better solution. This is ok because it already landed, but always nice to not be too hasty! |
Will do, sorry about the trouble. |
Is there an issue documenting the bloat problem? |
triage: beta-nominated Nominating for a backport as this fixes a reported regression with chipmunk-sys and is pretty harmless. |
The libs team decided to accept this for a backport to beta |
(12 was chosen to be consistent with what we do for tuples)
Fixes #28559