Skip to content

Commit 4bed1c1

Browse files
committed
Pass tidy again
1 parent b956b77 commit 4bed1c1

File tree

1 file changed

+1
-5
lines changed
  • alloc/src/collections/binary_heap

1 file changed

+1
-5
lines changed

alloc/src/collections/binary_heap/mod.rs

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -538,11 +538,7 @@ impl<T: Ord, A: Allocator> BinaryHeap<T, A> {
538538
/// otherwise it's *O*(1).
539539
#[stable(feature = "binary_heap_peek_mut", since = "1.12.0")]
540540
pub fn peek_mut(&mut self) -> Option<PeekMut<'_, T, A>> {
541-
if self.is_empty() {
542-
None
543-
} else {
544-
Some(PeekMut { heap: self, original_len: None })
545-
}
541+
if self.is_empty() { None } else { Some(PeekMut { heap: self, original_len: None }) }
546542
}
547543

548544
/// Removes the greatest item from the binary heap and returns it, or `None` if it

0 commit comments

Comments
 (0)