diff options
Diffstat (limited to 'library/alloc/src/str.rs')
| -rw-r--r-- | library/alloc/src/str.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/library/alloc/src/str.rs b/library/alloc/src/str.rs index 6fee8d3fe33..a670bb5008a 100644 --- a/library/alloc/src/str.rs +++ b/library/alloc/src/str.rs @@ -604,6 +604,10 @@ impl str { /// Converts a boxed slice of bytes to a boxed string slice without checking /// that the string contains valid UTF-8. /// +/// # Safety +/// +/// * The provided bytes must contain a valid UTF-8 sequence. +/// /// # Examples /// /// ``` |
