Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
svnpenn
on Sept 22, 2020
|
parent
|
context
|
favorite
| on:
My least favorite Rust type
In Go, you can use an interface to implement private struct fields. Then you can make a "New" function to implement default values as needed. I made a post about this last month:
https://stackoverflow.com/a/63552596
Consider applying for YC's Spring batch! Applications are open till Feb 11.
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search:
https://stackoverflow.com/a/63552596