Skip to content

Commit 65000a0

Browse files
author
balt-dev
committed
Fix formatting
1 parent b3bcc89 commit 65000a0

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

library/alloc/src/vec/mod.rs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2503,7 +2503,7 @@ impl<T, A: Allocator> Vec<T, A> {
25032503
Ok(())
25042504
}
25052505

2506-
/// Appends an element to the back of a collection, returning a reference to it.
2506+
/// Appends an element to the back of a collection, returning a reference to it.
25072507
///
25082508
/// # Panics
25092509
///
@@ -2517,7 +2517,7 @@ impl<T, A: Allocator> Vec<T, A> {
25172517
/// # #[allow(unused)]
25182518
/// #[derive(PartialEq, Eq, Debug)]
25192519
/// struct Item { identifier: &'static str, count: usize }
2520-
///
2520+
///
25212521
/// impl Default for Item {
25222522
/// fn default() -> Self {
25232523
/// return Self { identifier: "stone", count: 64 }
@@ -2579,13 +2579,14 @@ impl<T, A: Allocator> Vec<T, A> {
25792579
/// # Time complexity
25802580
///
25812581
/// Takes *O*(1) time.
2582-
#[inline]
2583-
2582+
//
25842583
// Since there's currently no way to have multiple unstable attributes on the same item, I compromised.
25852584
// Uncomment/delete the respective attribute when its respective issue stabilizes, since this falls under both.
2585+
//
25862586
#[unstable(feature = "push_mut", issue = "135974")]
25872587
// #[unstable(feature = "vec_push_within_capacity", issue = "100486")]
2588-
2588+
//
2589+
#[inline]
25892590
#[must_use = "if you don't need a reference to the value, use Vec::push_within_capacity instead"]
25902591
pub fn push_mut_within_capacity(&mut self, value: T) -> Result<&mut T, T> {
25912592
if self.len == self.buf.capacity() {

0 commit comments

Comments
 (0)