News for hackers. Stuff that matters.
Re:Sshole by jppittma on Thursday November 05, 2026 @10:02AM (#50379968)
Where are you going with those goal posts?
Re:Sshole by Philpax on Thursday November 05, 2026 @10:48AM (#50380608)
Nowhere. It's the same argument as upthread. A language that forces downstream consumers of an API to correctly deal with all possible outcomes would have prevented this.
Re:Sshole by jppittma on Saturday November 07, 2026 @01:54PM (#50406966)
You can’t force downstream to do anything. I can write a library in C that hints just as hard as rust does though, using basically the same tools/apis, since they’re all there. The only difference is that it’s less conventional in C. That’s probably a smaller lift than rewrite it in rust.

Memory is where C is broken. I feel like without `defer` or destructors the language meaningfully is incomplete.

Re:Sshole by rini17 on Thursday November 05, 2026 @10:58AM (#50380768)
Goalposts are fine. If crypt did return union type, C still allows cowboy programmers to straight extract the char* without any check whether it's valid.
Re:Sshole by cannonpalms on Thursday November 05, 2026 @11:20AM (#50381013)
I don't think the goal posts were moved. The comment you replied to referred to the "use"--not the existence--of sum types.