Home for the Unsafe Code Guidelines (UCG) effort. The goal of the Unsafe Code Guidelines effort is to collaboratively produce a "reference guide" for writing unsafe code that what kinds of things unsafe code can and cannot do.
Active area of discussion
At any given time, the UCG working group is focused on one particular area. The current area is Validity Invariants -- read that link for more background and information. You can find the current discussion threads here.
Ideas for future "areas of discussion" are represented as issues labeled with the "proposed discussion topic" label. Feel free to open more such issues if you have a question that doesn't match any of the existing issues!
For people who are interested in this sort of thing, there is a team
in the rust-lang org called
WG-unsafe-code-guidelines. Send a
private message to @nikomatsakis on internals if you would like to
be added. This team is commonly cc'd when curious situations arise.
Being a member of this GitHub team simply indicates that you would
like to be notified and does not imply any particular decision making
The "Unsafe Code Guidelines Reference"
Results from past discussions are written up in the "Unsafe Code Guidelines Reference", which lives in this repository. It is largely a work-in-progress right now. Note that, unless we state otherwise, the information in there is mostly a "recommendation" and still subject to change -- once made official, the intention is to migrate this information into the Rust Reference proper. Read the "Unsafe Code Guidelines Reference" here.
Make sure that
mdbook is installed:
cargo install mdbook
mdbook build or
mdbook serve in the
Link to the current version of the book
Chat platform, discussion cadence
Most of the discussion takes place here in GitHub issues. Many of us
do hangout on Zulip, however, in the
Every two weeks on Thursday at 9:00 UTC-4 (13:00 UTC), we hold a brief, non-technical meeting to decide whether to keep the current area of discussion or to adopt a new one. Prior to this meeting, we update the "area of discussion" document with summaries of the threads. The meeting takes place on Zulip and all are welcome to attend.
A more complete description of our process can be found in the
The Rustonomicon is a draft document discussing unsafe code. It is intended to be brought into agreement with the content here. It represents an organized effort to explain how to write Rust code, rather than a reference.
The nikomatsakis/rust-memory-model repository was a previous effort and contains a lot of good links and info.