mirror of
https://github.com/rust-lang/rust.git
synced 2026-05-08 09:38:26 +03:00
Rollup merge of #66744 - chrisduerr:master, r=Dylan-DPC
Fix shrink_to panic documentation While the potential for panicking is already documented for the `Vec::shrink_to` method, it is not clearly labeled with the usual `# Panics` heading. r? @steveklabnik
This commit is contained in:
@@ -629,6 +629,8 @@ pub fn shrink_to_fit(&mut self) {
|
||||
/// The capacity will remain at least as large as both the length
|
||||
/// and the supplied value.
|
||||
///
|
||||
/// # Panics
|
||||
///
|
||||
/// Panics if the current capacity is smaller than the supplied
|
||||
/// minimum capacity.
|
||||
///
|
||||
|
||||
Reference in New Issue
Block a user