Skip to content

Commit

Permalink
MSRV
Browse files Browse the repository at this point in the history
  • Loading branch information
sffc committed Dec 23, 2023
1 parent 4a0048a commit 08af4f0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion utils/zerovec/src/zerovec/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,8 @@ impl<U> EyepatchHackVector<U> {
// Return a slice to the inner data
#[inline]
const fn as_slice<'a>(&'a self) -> &'a [U] {
unsafe { self.buf.as_ref() }
// Note: self.buf.as_ref() is not const until 1.73
unsafe { &*(self.buf.as_ptr() as *const [U]) }
}

/// Return this type as a vector
Expand Down

0 comments on commit 08af4f0

Please sign in to comment.