Auto merge of #123270 - JaniM:janim/string-alloc-doc, r=workingjubilee

doc: mention heap allocation earlier in String docs

Just a tiny addition.

Helps with #123263.
This commit is contained in:
bors 2024-03-31 22:39:04 +00:00
commit 66de611196

View File

@ -72,9 +72,9 @@
/// A UTF-8encoded, growable string.
///
/// The `String` type is the most common string type that has ownership over the
/// contents of the string. It has a close relationship with its borrowed
/// counterpart, the primitive [`str`].
/// `String` is the most common string type. It has ownership over the contents
/// of the string, stored in a heap-allocated buffer (see [Representation](#representation)).
/// It is closely related to its borrowed counterpart, the primitive [`str`].
///
/// # Examples
///