2 ms·
> Isn't this also true of Rust, with its unsafe keyword? > None of these languages are completely safe No, but the first time I encountered an unexplained seg
by mrsteveman1 10y ago
> Isn't this also true of Rust, with its unsafe keyword?
> None of these languages are completely safe
No, but the first time I encountered an unexplained segfault in Rust was the first time I've ever found & fixed the cause of a weird segfault message in just a few minutes, because the mistake was in the 12 lines I had written inside a clearly marked unsafe block rather than the other ~3000.
Without something like unsafe blocks, finding known bugs and auditing code for other "weird" memory issues means looking much wider (and often, screaming "what the hell are you talking about?!" at the screen on a routine basis).