-
-
Notifications
You must be signed in to change notification settings - Fork 130
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
Add default tag #131
Comments
I agree. The fundamental tradeoff with this library is the size of the crate due to the massive volume of code that serde generates. This will obviously exacerbate things further, however for the minute, while we are using Box everywhere, I believe the tradeoff is worth it. |
Also, as a sidenote, I've been ill with COVID over the holidays so that big block of time I was hoping to spend on this disappeared :( but I have managed to clear out the pull request backlog and close some issues. |
I had some time to have a look at the implications of adding default to the code. My assumption was that this was negligible, but I wanted to get some data on it: # current
> cargo expand --features runtime-async-std-surf | wc -l
730432
# with default
> cargo expand --features runtime-async-std-surf | wc -l
740943 Relatively minimal cost for a fairly major benefit imo |
@FL33TW00D Brought up a good point about defaults. I think that after the Option, Box switch is made we should try to add the Default tag to the generated structs, just like we do with Debug.
Thoughts?
The text was updated successfully, but these errors were encountered: