3 ms·
> the only thing you can do that you can't normally is dereference raw pointers. The type checker still runs by default, but unsafe allows you to opt out of it
by Nullabillity 8y ago
> the only thing you can do that you can't normally is dereference raw pointers.
The type checker still runs by default, but unsafe allows you to opt out of it selectively (with std::mem::transmute[0]). The same way that borrows are still checked, but unsafe allows you to opt out by using raw pointers (as you mentioned).
[0]: https://doc.rust-lang.org/std/mem/fn.transmute.html https://doc.rust-lang.org/std/mem/fn.transmute.html