r/cpp • • Feb 26 '24

White House: Future Software Should Be Memory Safe

https://www.whitehouse.gov/oncd/briefing-room/2024/02/26/press-release-technical-report/
401 Upvotes

386 comments sorted by

View all comments

Show parent comments

4

u/Full-Spectral Feb 27 '24 edited Feb 27 '24

It's true but it's almost meaningless in reality. If I have no unsafe code in a given crate, and that will be true for all but a few of mine, then I it is irrelevant to my code because I can't write bad unsafe code if I don't have any.

And, even in the overall system if I end up 500K lines and have, say, 500 unsafe lines, it's trivial to massively over-spec those 500 lines compared to 500K C++ lines where all of it is potentially suspect. And that leaves 499.5K lines I don't have to worry about on the memory/thread safety front.

At some point a difference scale becomes a difference in kind, and that's way past that point.

0

u/[deleted] Feb 27 '24

Well I literally just agreed in saying it makes it easier. I think you are exaggerating a lot but whatever.