Skip to content

Commit 605f2db

Browse files
committed
Rework diagnostics for wrong number of generic args
1 parent f8f1b15 commit 605f2db

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core/src/slice/raw.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ pub unsafe fn from_raw_parts<'a, T>(data: *const T, len: usize) -> &'a [T] {
103103
///
104104
/// Behavior is undefined if any of the following conditions are violated:
105105
///
106-
/// * `data` must be [valid] for boths reads and writes for `len * mem::size_of::<T>()` many bytes,
106+
/// * `data` must be [valid] for both reads and writes for `len * mem::size_of::<T>()` many bytes,
107107
/// and it must be properly aligned. This means in particular:
108108
///
109109
/// * The entire memory range of this slice must be contained within a single allocated object!

0 commit comments

Comments
 (0)