Skip to content

Commit 896d4bd

Browse files
committed
fixup
1 parent 6cbff7e commit 896d4bd

File tree

4 files changed

+6
-6
lines changed

4 files changed

+6
-6
lines changed

src/destructors.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ you don't want to drop in a `union`. The standard library provides the
2626
Consider a custom implementation of `Box`, which might write `Drop` like this:
2727

2828
```rust
29-
#![feature(unique, allocator_api)]
29+
#![feature(allocator_api)]
3030

3131
use std::heap::{Heap, Alloc, Layout};
3232
use std::mem;
@@ -52,7 +52,7 @@ use-after-free the `ptr` because when drop exits, it becomes inaccessible.
5252
However this wouldn't work:
5353

5454
```rust
55-
#![feature(allocator_api, unique)]
55+
#![feature(allocator_api)]
5656

5757
use std::heap::{Heap, Alloc, Layout};
5858
use std::ptr::drop_in_place;
@@ -124,7 +124,7 @@ The classic safe solution to preventing recursive drop and allowing moving out
124124
of Self during `drop` is to use an Option:
125125

126126
```rust
127-
#![feature(allocator_api, unique)]
127+
#![feature(allocator_api)]
128128

129129
use std::heap::{Alloc, Heap, Layout};
130130
use std::ptr::drop_in_place;

src/dropck-eyepatch.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -292,7 +292,7 @@ fn inspect() {
292292
}
293293
```
294294

295-
```
295+
```text
296296
error[E0597]: `*data` does not live long enough
297297
--> src/main.rs:37:1
298298
|

src/phantom-data.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ allocation which is used for multiple arrays of different types:
5151
```
5252
use std::marker;
5353
54-
struct HashMap {
54+
struct HashMap<K, V> {
5555
ptr: *mut u8,
5656
// The pointer actually stores keys and values
5757
// (and hashes, but those aren't generic)

src/vec-final.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# The Final Code
22

33
```rust
4-
#![feature(unique)]
4+
#![feature(shared)]
55
#![feature(allocator_api)]
66

77
use std::ptr::{Shared, self};

0 commit comments

Comments
 (0)