News for hackers. Stuff that matters.
Re:I am not yet ready to switch to Zig from Rust by koeng on Friday June 14, 2024 @12:26PM (#40682207)
That’s not true. Here is a go playground of pretty much that exact code running just fine

https://go.dev/play/p/v7OM9s_pRqY

Re:I am not yet ready to switch to Zig from Rust by deathanatos on Friday June 14, 2024 @12:51PM (#40682441)
Steelman their example. Given that they named the member "MaybeHasCat", it's pretty clearly meant to analogue an Option<Cat>; if you correct the small typo then (make the type of "MaybeHasCat" a pointer, so that it can store nil for the other half of the Maybe), the example behaves exactly as they describe.
Re:I am not yet ready to switch to Zig from Rust by iknowstuff on Tuesday June 18, 2024 @05:35AM (#40715702)
Wtf? what are you doing? Did the point fly over your head, are you being malicious by removing the star, or?
Re:I am not yet ready to switch to Zig from Rust by koeng on Wednesday June 19, 2024 @06:14PM (#40733003)
They added the star as an edit because of my playground link. So, neither