|
|
|
|
|
by hatefulmoron
393 days ago
|
|
The article says it right there: unsafe is used to give you unsafe superpowers. This is important for the quantum entanglement that the string uses. Unsafe brings the power (superpowers enabled by the compiler), while the Rust compiler ensures everything is safe. Rust. |
|
This is where you are mistaken. Quoting the book:
>Be warned, however, that you use unsafe Rust at your own risk: if you use unsafe code incorrectly, problems can occur due to memory unsafety, such as null pointer dereferencing.
With unsafe rust the compiler no longer ensures everything is safe and it is up to the programmer to ensure that it is.