We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e7949bc commit 44d8b4cCopy full SHA for 44d8b4c
src/liballoc/string.rs
@@ -671,6 +671,7 @@ impl String {
671
/// same allocator the standard library uses, with a required alignment of exactly 1.
672
/// * `length` needs to be less than or equal to `capacity`.
673
/// * `capacity` needs to be the correct value.
674
+ /// * The first `length` bytes at `buf` need to be valid UTF-8.
675
///
676
/// Violating these may cause problems like corrupting the allocator's
677
/// internal data structures.
0 commit comments