Hacker News new | past | comments | ask | show | jobs | submit login

You should have written it in Rust. Why? Because ... idk



Rust was still years away from 1.0 when this was written. If we consider Rust as it is today, it would address some of the author’s complaints about C++, but not all. Rust’s error handling is more explicit and supports fallible “constructors” (Rust doesn’t actually have a true concept of a constructor) – but it doesn’t support fallible destructors, and the standard library notably lacks the ability to cleanly handle out-of-memory conditions. Privacy is more flexible, and there’s not as much of a strict “object-oriented” focus. On the other hand, intrusive lists are arguably even worse than in C++, because they require a lot of unsafe code and don’t play well with the borrow checker (in particular, you can’t enforce unique access).




Join us for AI Startup School this June 16-17 in San Francisco!

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: