We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 7dfcd07 + 2b35eba commit 03697ebCopy full SHA for 03697eb
src/destructors.md
@@ -26,7 +26,7 @@ this is totally fine.
26
For instance, a custom implementation of `Box` might write `Drop` like this:
27
28
```rust
29
-#![feature(unique, allocator_api)]
+#![feature(ptr_internals, allocator_api)]
30
31
use std::heap::{Heap, Alloc, Layout};
32
use std::mem;
@@ -52,7 +52,7 @@ use-after-free the `ptr` because when drop exits, it becomes inaccessible.
52
However this wouldn't work:
53
54
55
-#![feature(allocator_api, unique)]
+#![feature(allocator_api, ptr_internals)]
56
57
58
use std::ptr::{drop_in_place, Unique};
@@ -123,7 +123,7 @@ The classic safe solution to overriding recursive drop and allowing moving out
123
of Self during `drop` is to use an Option:
124
125
126
127
128
use std::heap::{Alloc, Heap, Layout};
129
src/vec-final.md
@@ -1,7 +1,7 @@
1
# The Final Code
2
3
4
-#![feature(unique)]
+#![feature(ptr_internals)]
5
#![feature(allocator_api)]
6
7
use std::ptr::{Unique, self};
src/vec-layout.md
@@ -71,7 +71,7 @@ take the hit and use std's Unique:
71
72
73
74
75
76
77
0 commit comments