|
|
|
|
|
by jakewins
716 days ago
|
|
Man I get vertigo reading this. Reminds me of trying to understand Java constructors and object initialisation. It’s been a while now, and at least in my experience so far Go and Rusts choice of not having special constructors really simplifies a lot. Is there anyone that’s had the experience of missing constructors once you swapped away from them? |
|
Unless you want to `ptr::write` individual fields by hand into a `MaybeUninit`, which you can absolutely do mind but that… is not very ergonomic, and requires structs to be specifically opted into this.