about summary refs log tree commit diff
path: root/library/alloc/src/string.rs
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2024-02-27 00:55:14 +0000
committerbors <bors@rust-lang.org>2024-02-27 00:55:14 +0000
commit71ffdf7ff7ac6df5f9f64de7e780b8345797e8a0 (patch)
treeae290c8dcb8654460eff1ca65a6ecafa8caf874d /library/alloc/src/string.rs
parent5c786a7fe307acf8b0143e1186c8799840da4095 (diff)
parentec5c5b7da8822122325d45625b9978fd3f05d84f (diff)
downloadrust-71ffdf7ff7ac6df5f9f64de7e780b8345797e8a0.tar.gz
rust-71ffdf7ff7ac6df5f9f64de7e780b8345797e8a0.zip
Auto merge of #121655 - matthiaskrgr:rollup-qpx3kks, r=matthiaskrgr
Rollup of 4 pull requests

Successful merges:

 - #121598 (rename 'try' intrinsic to 'catch_unwind')
 - #121639 (Update books)
 - #121648 (Update Vec and String `{from,into}_raw_parts`-family docs)
 - #121651 (Properly emit `expected ;` on `#[attr] expr`)

r? `@ghost`
`@rustbot` modify labels: rollup
Diffstat (limited to 'library/alloc/src/string.rs')
-rw-r--r--library/alloc/src/string.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/library/alloc/src/string.rs b/library/alloc/src/string.rs
index 6dadbc8e364..1d3c04f7807 100644
--- a/library/alloc/src/string.rs
+++ b/library/alloc/src/string.rs
@@ -864,7 +864,7 @@ impl String {
         }
     }
 
-    /// Decomposes a `String` into its raw components.
+    /// Decomposes a `String` into its raw components: `(pointer, length, capacity)`.
     ///
     /// Returns the raw pointer to the underlying data, the length of
     /// the string (in bytes), and the allocated capacity of the data
@@ -896,7 +896,7 @@ impl String {
         self.vec.into_raw_parts()
     }
 
-    /// Creates a new `String` from a length, capacity, and pointer.
+    /// Creates a new `String` from a pointer, a length and a capacity.
     ///
     /// # Safety
     ///