logoalt Hacker News

hota_mazitoday at 4:11 PM1 replyview on HN

What do you mean?

C is unsafe 100% of the time. Rust is only unsafe in unsafe{} blocks.


Replies

ueckertoday at 5:30 PM

This is nonsense. There is quite a subset of C which is perfectly safe and an even larger one which can easily be safe with tooling. You could argue that unsafe keyword is easier to spot than the unsafe features of C, so that makes it somewhat easier to screen for issues. But if you screen for memory safety only, this is problematic anyhow.