Closed tingfeng-key closed 1 year ago
This is probably possible by making partial_unchecked
emit its own macro_rules
that can construct CreateParams
from UpdateParams
, but I feel like it's just not worth it compared to how much effort it would take. Besides, I don't thinkCreateParams
and UpdateParams
will be interchangeable in 0.7.0 anyway.
ok, that would be really cool if it came to fruition one day
CreateParams
and UpdateParams
definitely aren't going to be compatible with each other in future, plus doing this would be wayyy to much overhead for me to maintain.
Understood, thank you for your reply. I will close it
For example, I have a
CreateParams
as follows:Then I need to add a username field when updating, so I need to copy
CreateParams
. Is it possible to expand on the basis ofCreateParams
, such as this:UpdateParams is now as follows: