File tree 3 files changed +6
-15
lines changed
3 files changed +6
-15
lines changed Original file line number Diff line number Diff line change @@ -913,7 +913,7 @@ impl<T> *const [T] {
913
913
/// The returned value is the number of **elements**, not the number of bytes.
914
914
///
915
915
/// This function is safe, even when the raw slice cannot be cast to a slice
916
- /// reference because the pointer is null or unaligned.
916
+ /// reference (e.g. because the pointer is null or unaligned) .
917
917
///
918
918
/// # Examples
919
919
///
@@ -1037,8 +1037,8 @@ impl *const str {
1037
1037
///
1038
1038
/// The returned value is the number of **bytes**, not the number of characters.
1039
1039
///
1040
- /// This function is safe, even when the raw string slice cannot be cast to a slice
1041
- /// reference because the pointer is null or unaligned.
1040
+ /// This function is safe, even when the raw string slice cannot be cast to a string slice
1041
+ /// reference (e.g. because the pointer is null or unaligned) .
1042
1042
///
1043
1043
/// # Examples
1044
1044
///
@@ -1085,9 +1085,6 @@ impl *const str {
1085
1085
///
1086
1086
/// [undefined behavior]: https://doc.rust-lang.org/reference/behavior-considered-undefined.html
1087
1087
///
1088
- /// Note that calling this function with an index that does not lie on an UTF-8 sequence boundaries
1089
- /// is safe, but dereferencing the pointer returned by such call is unsound.
1090
- ///
1091
1088
/// # Examples
1092
1089
///
1093
1090
/// ```
Original file line number Diff line number Diff line change @@ -1176,7 +1176,7 @@ impl<T> *mut [T] {
1176
1176
/// The returned value is the number of **elements**, not the number of bytes.
1177
1177
///
1178
1178
/// This function is safe, even when the raw slice cannot be cast to a slice
1179
- /// reference because the pointer is null or unaligned.
1179
+ /// reference (e.g. because the pointer is null or unaligned) .
1180
1180
///
1181
1181
/// # Examples
1182
1182
///
@@ -1353,8 +1353,8 @@ impl *mut str {
1353
1353
///
1354
1354
/// The returned value is the number of **bytes**, not the number of characters.
1355
1355
///
1356
- /// This function is safe, even when the raw string slice cannot be cast to a slice
1357
- /// reference because the pointer is null or unaligned.
1356
+ /// This function is safe, even when the raw string slice cannot be cast to a string slice
1357
+ /// reference (e.g. because the pointer is null or unaligned) .
1358
1358
///
1359
1359
/// # Examples
1360
1360
///
@@ -1406,9 +1406,6 @@ impl *mut str {
1406
1406
///
1407
1407
/// [undefined behavior]: https://doc.rust-lang.org/reference/behavior-considered-undefined.html
1408
1408
///
1409
- /// Note that calling this function with an index that does not lie on an UTF-8 sequence boundaries
1410
- /// is safe, but dereferencing the pointer returned by such call is unsound.
1411
- ///
1412
1409
/// # Examples
1413
1410
///
1414
1411
/// ```
Original file line number Diff line number Diff line change @@ -708,9 +708,6 @@ impl NonNull<str> {
708
708
///
709
709
/// [undefined behavior]: https://doc.rust-lang.org/reference/behavior-considered-undefined.html
710
710
///
711
- /// Note that calling this function with an index that does not lie on an UTF-8 sequence boundaries
712
- /// is safe, but dereferencing the pointer returned by such call is unsound.
713
- ///
714
711
/// # Examples
715
712
///
716
713
/// ```
You can’t perform that action at this time.
0 commit comments