mirror of
https://github.com/rust-lang/rust.git
synced 2024-11-01 23:12:02 +00:00
Rollup merge of #36326 - JDemler:master, r=steveklabnik
Fixed typo in nomicon
This commit is contained in:
commit
8bfc561752
@ -52,7 +52,7 @@ let mut data = vec![1, 2, 3];
|
||||
let x = &data[0];
|
||||
|
||||
// OH NO! `push` causes the backing storage of `data` to be reallocated.
|
||||
// Dangling pointer! User after free! Alas!
|
||||
// Dangling pointer! Use after free! Alas!
|
||||
// (this does not compile in Rust)
|
||||
data.push(4);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user