Get the latest tech news
Making unsafe Rust a little safer
This article will look at tools for verifying unsafe Rust code, including unsafe code called from libraries written in C or C++.
While the sanitizer detected the same error, Miri’s output is more specific and easier to interpret, including code snippets rather than memory addresses and stack frames. Miri successfully identifies the data race and includes specific code snippets and errors that are much easer to interpret than the output from the Rust ThreadSanitizer example above: This article explored three techniques for verifying unsafe Rust code to make it safer and ensure it avoids undefined behaviours that can result in serious operational consequences, everything from malfunctions, security vulnerabilities, regulatory violations, economic loss, human injury, and death.
Or read this on Hacker News