Skip to content

Commit afb11c3

Browse files
committed
Address review comment.
1 parent 2c76c6b commit afb11c3

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

reference/src/layout/pointers.md

+6-1
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ struct DynObject {
5151
}
5252
```
5353

54+
> **note**: In the layout equivalence of `&dyn mut Trait` the field `data` is of the type `*mut u8`.
55+
5456
The layout of `&[T]` is the same as that of:
5557
```rust
5658
#[repr(C)]
@@ -60,4 +62,7 @@ struct Slice<T> {
6062
}
6163
```
6264

63-
The layout of `&str` is the same as that of `&[u8]`.
65+
> **note**: In the layout equivalence of `&mut [T]` the field `ptr` is of the type `*mut T`.
66+
67+
The layout of `&str` is the same as that of `&[u8]`, and the layout of `&mut str` is
68+
the same as that of `&mut [u8]`.

0 commit comments

Comments
 (0)