Add TryFromBytes::try_{ref,mut}_from_{bytes,prefix,suffix}_with_elems#1747
Add TryFromBytes::try_{ref,mut}_from_{bytes,prefix,suffix}_with_elems#1747
Conversation
5cdb8d8 to
b0d1b2f
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1747 +/- ##
==========================================
- Coverage 88.01% 87.13% -0.89%
==========================================
Files 16 16
Lines 5833 5892 +59
==========================================
Hits 5134 5134
- Misses 699 758 +59 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
b0d1b2f to
cb103be
Compare
|
Hit merge when you're satisfied, @joshlf. |
| count: usize, | ||
| ) -> Result<&mut Self, TryCastError<&mut [u8], Self>> | ||
| where | ||
| Self: KnownLayout<PointerMetadata = usize> + Immutable, |
There was a problem hiding this comment.
Remove the Immutable bound?
| count: usize, | ||
| ) -> Result<(&mut Self, &mut [u8]), TryCastError<&mut [u8], Self>> | ||
| where | ||
| Self: KnownLayout<PointerMetadata = usize> + Immutable, |
There was a problem hiding this comment.
Remove the Immutable bound?
| count: usize, | ||
| ) -> Result<(&mut [u8], &mut Self), TryCastError<&mut [u8], Self>> | ||
| where | ||
| Self: KnownLayout<PointerMetadata = usize> + Immutable, |
There was a problem hiding this comment.
Remove the Immutable bound?
Makes progress on #5
| /// use zerocopy::*; | ||
| /// # use zerocopy_derive::*; | ||
| /// | ||
| /// #[derive(TryFromBytes, Immutable, KnownLayout)] |
There was a problem hiding this comment.
Don't derive Immutable here?
| /// # use zerocopy_derive::*; | ||
| /// | ||
| /// // The only valid value of this type is the byte `0xC0` | ||
| /// #[derive(TryFromBytes, KnownLayout, Immutable)] |
There was a problem hiding this comment.
Don't derive Immutable here?
| /// # use zerocopy_derive::*; | ||
| /// | ||
| /// // The only valid value of this type is the byte `0xC0` | ||
| /// #[derive(TryFromBytes, KnownLayout, Immutable)] |
There was a problem hiding this comment.
Don't derive Immutable here?
| /// use zerocopy::*; | ||
| /// # use zerocopy_derive::*; | ||
| /// | ||
| /// #[derive(TryFromBytes, Immutable, KnownLayout)] |
There was a problem hiding this comment.
Don't derive Immutable here?
| /// # use zerocopy_derive::*; | ||
| /// | ||
| /// // The only valid value of this type is the byte `0xC0` | ||
| /// #[derive(TryFromBytes, KnownLayout, Immutable)] |
There was a problem hiding this comment.
Don't derive Immutable here?
| /// use zerocopy::*; | ||
| /// # use zerocopy_derive::*; | ||
| /// | ||
| /// #[derive(TryFromBytes, Immutable, KnownLayout)] |
There was a problem hiding this comment.
Don't derive Immutable here?
cb103be to
95a8ca7
Compare
|
Awesome, queued! |
Makes progress on #5