4 ms·
Rewriting isn't the solution to everything, unless the code is really small and well-contained. High-profile security bugs were found in programs written in C#
by sn_master 6y ago
Rewriting isn't the solution to everything, unless the code is really small and well-contained.
High-profile security bugs were found in programs written in C# and Java and every other "safe" language out there.
The unknown-unknowns are often far worse than what you currently have. Check the Uber Swift rewrite horror that was posted last week, and that was a super tiny app compared to even the smallest Office app.
Another critical factor is: C++ is currently the only true "portable" language out there, that can be compiled into Windows/Mac/iOS/Android and everything else that exists or will come up in the future. Nothing else comes even close in terms of native platform support. And its completely unrealistic to have copies with different languages for each platform like "small" apps do like Uber or Facebook. We're talking about business logic that if it isn't exactly the same everywhere (with its bugs), people can lose billions of dollars.
Even if Rust can compile into all of those platforms, I assure you, there will be dozens of very serious compiler bugs that will be uncovered over time if an app the size of Office gets rewritten into it. A good number of those will be of serious security consequences. Hell, back in the day, Excel had its own C++ compiler because of compiler bugs that couldn't be fixed on time!
- Shared404 6y ago> C++ is currently the only true "portable" language out there, I thought that was C? Or am I misunderstanding, and you're using C++ because it's more advanced and can still be used anywhere C can?
- a1369209993 6y agoMicrosoft is somewhat notorious for not correctly supporting C in Visual Studio. There's MinGW, which basically works, but it arguably doesn't count as 'native' support. I've heard people claim that recent versions of VS are better, but I've also heard people claim that they just corrupted the standards process to get everything they didn't support relegated to optional extensions, so... [shrug].
- asddubs 6y agoyou can also use clang these days without MinGW AFAIK
- sn_master 6y agoYes, you're right, C is more accurate, tho C has been getting more and more C++ features over time.
- xavierlint 6y agoYou don't even have to go as far as compiler bugs, there WILL be application bugs after a rewrite.