Skip to content

Fix 20.1 Miri unsafe code section #4401

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

abemassry
Copy link

Fixes #4338 Wrong concept in subsection "Using Miri to check unsafe code" of section "20.1. Unsafe Rust"

This is a followup to PR #4062

This PR adds a working example of using Miri where the code will compile and run without warnings or errors, but with undefined behavior while it runs. After running it through Miri though it correctly identifies the data race.

Feedback welcome on matching the text to the books style. Or if anyone wants to collaborate on other examples of Miri output.

Fixes rust-lang#4338 Wrong concept in subsection "Using Miri to check unsafe code"
of section "20.1. Unsafe Rust"

This is a followup to PR rust-lang#4062

This PR adds a working example of using Miri where the code will compile
and run without warnings or errors, but with undefined behavior while it
runs. After running it through Miri though it correctly identifies the
data race.

Feedback welcome on matching the text to the books style. Or if anyone
wants to collaborate on other examples of Miri output.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Wrong concept in subsection "Using Miri to check unsafe code" of section "20.1. Unsafe Rust"
1 participant