
What does ed rust think about what is going on with state farm code#
It doesn't just let bad code slide on through.

If you do something dumb, it's going to take that code, set it on the table, and patiently point out to you how you can make it better. But, more than just performance or security, the Rust compiler is almost like having a senior programmer sitting next to you all day long. The Rust language is interesting now because of the situation we're in with regards to security, and the performance that it offers is very compelling, better than C or C++ in many cases for naively written code. I believe that Rust will prevent many exploits in the future, but I think timeliness is a huge factor. Why would a user want security-focused code that runs 10% slower when all they care about is performance? The world was a different place back then. Before then, most computers weren't really networked, and the ones that were networked were connected to very slow modems. So, why didn't everyone just write their code in Ada and avoid all the problems? Ada performance was almost certainly measurably slower than what C had to offer, but also C allows programmers to be lazier, and most programmers are lazy by default, so it was a nice relationship, or so it seemed at the time.Īnother compounding factor to consider is that most programmers didn't start to think about vulnerabilities and exploits in earnest until the mid-90's. In fact, Ada was released in 1983, I think, and it offers a huge chunk of Rust's functionality. With modern compiler technology, Rust is able to offer safety and performance in a somewhat ergonomic package, which is just not practical to have expected back in the 70's. So, programmers back in the 70's would have turned off all of Rust's safety features in pursuit of performance. Compilers didn't become effective at optimization until the late 90's or early 2000's. If you use the language the way it is intended, then most of these bounds checks can be elided (disappeared), but this is only thanks to modern compiler technology. Rust is willing to trade a few percentage points of performance if it means safety guarantees, which is exactly what happens with bounds checking. Back in the 70's, processors were something like 4 orders of magnitude slower than what we have now. Rust allows a programmer to be as unsafe as they want, so you can reproduce every sec vuln that C has to offer in Rust, if you start throwing the unsafe keyword around like candy. So, how many would Rust have prevented? That's incredibly difficult to say. Actually, there are a lot of other features that Rust kinda revolves around, but I'm trying to answer your question, not rewrite the Rust Book. Some of the big features of Rust revolve around preventing pointer-aliasing both at a language-design-level and at runtime by bounds checking, invalid computational states are avoided as much as possible by using Algebraic Sum Types, since these allow the compiler to enforce that you are always in a valid computational state, rather than relying on the programmer to do a good job of maintaining state. If it isn't functionally better than C, then we need to take a step back and reconsider everything. Rust is the beneficiary of decades of computer science research. If not to make a better language, why design a new one at all? Philosophically, the reason why programming languages are designed is to somehow improve the current state of the art. We'll do our best to keep these links up to date, but if we fall behind please don't hesitate to shoot us a modmail.

This is not an official Rust forum, and cannot fulfill feature requests. Err on the side of giving others the benefit of the doubt.Īvoid re-treading topics that have been long-settled or utterly exhausted.

Please create a read-only mirror and link that instead.Ī programming language is rarely worth getting worked up over.īe charitable in intent. If criticizing a project on GitHub, you may not link directly to the project's issue tracker. Post titles should include useful context.įor Rust questions, use the stickied Q&A thread.Īrts-and-crafts posts are permitted on weekends.Ĭriticism is encouraged, though it must be constructive, useful and actionable. For content that does not, use a text post to explain its relevance. Posts must reference Rust or relate to things using Rust. We observe the Rust Project Code of Conduct. Strive to treat others with respect, patience, kindness, and empathy. Please read The Rust Community Code of Conduct The Rust Programming LanguageĪ place for all things related to the Rust programming language-an open-source systems language that emphasizes performance, reliability, and productivity.
