Skip to content

Commit

Permalink
Fix clippy warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
Rexagon committed Jul 27, 2023
1 parent 62ed038 commit 72fa798
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/cell/slice.rs
Original file line number Diff line number Diff line change
Expand Up @@ -198,12 +198,14 @@ impl OwnedCellSlice {
}

/// Returns an immutable reference to the underlying slice.
#[allow(clippy::should_implement_trait)]
#[inline]
pub fn as_ref<'a>(&'a self) -> &'a CellSlice<'a> {
pub fn as_ref(&'_ self) -> &'_ CellSlice<'_> {
&self.cell_slice
}

/// Returns a mutable reference to the underlying slice.
#[allow(clippy::should_implement_trait)]
#[inline]
pub fn as_mut<'a>(&'a mut self) -> &'a mut CellSlice<'a> {
// SAFETY: cell reference points to the pinned location
Expand Down

0 comments on commit 72fa798

Please sign in to comment.