3 ms·
Switching to a safe language is, obviously, not an option. However, it is possible, especially with resources of Google and other C++ shops to develop an advan
by johndoe42377 6y ago
Switching to a safe language is, obviously, not an option.
However, it is possible, especially with resources of Google and other C++ shops to develop an advanced lint, which could be just a ripoff of compile time borrow checking from Rust (taking into account complexity of c++ memory model).
Flagging simple things like use after free would already be a big deal.
Nowadays it probably should be a plugin for clang or something similar instead of lint.
- steveklabnik 6y agoThis is what the Core Guidelines are trying to do. Well, it's only attempting to tackle part of what Rust does.
- titzer 6y agoWe should have more courage and attempt big things. Like writing the program we already wrote....again. We take this option off the table. Cannot rewrite. Definitely not in a safe language! Surely we have ceased to dream?
- adev_ 6y ago> We should have more courage and attempt big things. > Like writing the program we already wrote....again. That's not named courage, that's named stupidity. Specially when the program you talk about is several millions lines of code and the results of years en engineering of entire teams. > We take this option off the table. Cannot rewrite. Definitely not in a safe language! Surely we have ceased to dream? There is people that dreams and there is the one that code. Evolution are (almost) always preferrable to Revolution. In this case, Evolution can mean: - Rewrite progressively the security sensible part in Rust mixed with the legacy (aka the Mozilla way) - Develop the tooling to make C++ safer/ or even better safe. That has already been done for a subset in the aeronautic industry - Work with the comitte to make C++ itself safer, which Google is already doing.
- mamcx 6y ago> Switching to a safe language is, obviously, not an option. Forever, never, ever, ever? Switch, right now, is not a good idea, but NEVER switch is the cobol curse. And not forget: C/C++ cause BILLONS of damage and costs in this industry. Is WELL KNOW, for DECADES that is the wrong tool for the job. Yet, the persisten myth that "lets not rewrite to something better" hold everything back. Imagine how stupid will any of us look if a customer ask us for build a new version of the software (or port to the web, or to mobile or cloud) and we say "nope, sorry. Is not good. Not rewrite sir!" Or if the software WE build have be caught, OFTEN with severe security and reliability bugs and we answer equally "we can't do anything better, is not a option". Dumb, right? Why rewrite is ok, normal and good for others, but not us? And why the excuse that the MOST PROFITABLES COMPANIES IN THE WORLD (Apple, Google, MS, ...) can't do rewrite, is too costly.... and then the rest PAY the cost anyway, with not solution on sight...