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
Support manually-created and generated conversion functions #7832
Support manually-created and generated conversion functions #7832
Conversation
7483383
to
fb53234
Compare
Test case that proves a generated conversion is overriden? |
fb53234
to
458fec6
Compare
Good point - test added. |
I'm going to grab this |
LGTM |
Thanks @smarterclayton ! I think that it would be good for @lavalamp to also take a look into it. |
Support manually-created and generated conversion functions
// used if recursive conversion calls are desired). It must return an error. | ||
// | ||
// Example: | ||
// c.RegisteConversionFunc( |
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.
nit: missing r
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.
Will fix that in a subsequenct PR
Thanks for fixing this! |
Is there somewhere I can read an overview of this changeset? I was very familiar with the state before autogeneration, and I want to understand what this is buying us and how I interact with it for manual conversion functions... |
The overview is that we're autogenerating conversion functions--while allowing manual override--instead of using the conversion logic. |
As an occasional author of manual conversion functions, what has changed On Wed, May 6, 2015 at 3:49 PM, Daniel Smith notifications@github.com
|
@wojtek-t can confirm (and we'll want to write this up really soon), but I believe the steps will be:
|
I did this today for the etcd portal ip allocator and was easy (not quite fully documented yet).
|
Part of #6800
This was mentioned in #7556 (comment)
Motivated by #7814, where a lot of unnecessary boilerplate had to be written.
cc @smarterclayton @lavalamp @fgrzadkowski