Live data from Hacker News

I cannot consistently write safe C/C++ code

robert.ocallahan.org

121–123 of 123 posts

Re: I cannot consistently write safe C/C++ code

#121

Earlier quoted context omitted.

As far as I understand, there is no accepted formal specification or even single source of truth for what the rust community thinks are the "rust memory safety guarantees". Only a large number of people that have completely convinced each other that "it's better than C++" with little proof and without even clearly defining their own semantics. Please correct me if I'm wrong here (a blog post does not qualify as a spe…

Trolling you? Go fuck yourself

Comments like these aren't OK on Hacker News, no matter what you're replying to.

https://news.ycombinator.com/newsguidelines.html

Re: I cannot consistently write safe C/C++ code

#122
post #7

Earlier quoted context omitted.

Good risk management is about cost vs payoff analysis. To address the risk of car accident, first you stop juggling chainsaws while driving, then you start to wear seatbelts, and then you start thinking about how the remaining inevitable driving mistakes can be mitigated through technology or practices.

I guess using C is analogous is juggling chainsaws in your analogy. But is that actually less safe? Consider a component actually responsible for preventing car accidents, such as the anti-lock brake system. It will consist of input sensors, output signals, and an embedded computer running some code. All of these components have gone through an extensive qualification process. On the software side, the coding standar…

This sounds like a very specialized C subset with nonstandad compilers, tooling and highly restricted functionality. Why use C as the starting point for such a language, instead of a hereditarily safer language like Pascal, Ada, etc?
Post reply on HN