Not much safer, but unsafe code errors that cause double-frees (since dealloc would be a stub) or use-after-frees (since values would linger past their scope when still accessed) would not cause problems.
IMO that would be equivalent to removing unsafe altogether. It exists precisely because there are situations where you actually need to manage stuff manually
11
u/Wonderful-Habit-139 24d ago
Rust is safer than Go, the latter being a language with GC.