Skip to content

Commit

Permalink
Clarify what Behavior Considered Undefined means.
Browse files Browse the repository at this point in the history
Fixes rust-lang#19

Thanks to @durka for providing the initial sentence.
  • Loading branch information
Havvy committed Sep 27, 2017
1 parent 669d225 commit 9bf9f64
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions src/behavior-considered-undefined.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
## Behavior considered undefined

The following is a list of behavior which is forbidden in all Rust code,
including within `unsafe` blocks and `unsafe` functions. Type checking provides
the guarantee that these issues are never caused by safe code.
Rust code, including within `unsafe` blocks and `unsafe` functions is incorrect
if it exhibits any of the behaviors in the following list. It is the
programmer's responsibility when writing `unsafe` code that it is not possible
to let `safe` code exhibit these behaviors.

* Data races.
* Dereferencing a null or dangling raw pointer.
Expand Down

0 comments on commit 9bf9f64

Please sign in to comment.