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
Proposal: Generics for CustomValidator & CustomDefaulter #2675
Comments
@ahmetb: The label(s) In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
@ahmetb are you sure this is possible? My understanding is that it isn't due to golang/go#49085, the |
I will give it a shot. I hit that in porting go-linq to generics as well. |
The Kubernetes project currently lacks enough contributors to adequately respond to all issues. This bot triages un-triaged issues according to the following rules:
You can:
Please send feedback to sig-contributor-experience at kubernetes/community. /lifecycle stale |
CustomValidator and CustomDefaulter interfaces could use generics support to potentially shorten the handler funcs like this:
to
Also statements like:
can probably be inferred with more type safety (right now there's nothing ensures a & b are handlers of the same type in
WithDefaulter(a).WithDefaulter(b)
?). e.g./kind proposal
/kind feature
The text was updated successfully, but these errors were encountered: