Skip to content

Commit a79047d

Browse files
authored
Merge pull request #1715 from RalfJung/ref-non-null
references and Box must be non-null
2 parents b06e1f3 + 0249aec commit a79047d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/behavior-considered-undefined.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -214,7 +214,7 @@ r[undefined.validity.union]
214214
Further details are [still being debated](https://github.com/rust-lang/unsafe-code-guidelines/issues/438).
215215

216216
r[undefined.validity.reference-box]
217-
* A reference or [`Box<T>`] must be aligned, it cannot be [dangling], and it must point to a valid value
217+
* A reference or [`Box<T>`] must be aligned and non-null, it cannot be [dangling], and it must point to a valid value
218218
(in case of dynamically sized types, using the actual dynamic type of the
219219
pointee as determined by the metadata).
220220
Note that the last point (about pointing to a valid value) remains a subject of some debate.

0 commit comments

Comments
 (0)