Skip to content

Conversation

@joshlf
Copy link
Member

@joshlf joshlf commented Feb 22, 2024

Previously, our test harness for TryFromBytes types assumed that those types also implemented NoCell. This commit introduces machinery that allows us to conditionally execute certain steps of our tests depending on whether or not the type under test implements NoCell.

This commit also lifts the T: NoCell bound in TryFromBytes for MaybeUninit<T> in order to test this machinery.

@joshlf joshlf requested a review from jswrenn February 22, 2024 16:09
@joshlf joshlf enabled auto-merge February 22, 2024 16:10
@joshlf joshlf force-pushed the maybe-uninit-no-cell-try-from-bytes branch from eb3782d to 8e63e62 Compare February 22, 2024 16:10
jswrenn
jswrenn previously approved these changes Feb 22, 2024
Copy link
Collaborator

@jswrenn jswrenn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, I can't say I approve of this in the moral sense, but I will approve it. 😅

@joshlf joshlf force-pushed the maybe-uninit-no-cell-try-from-bytes branch 6 times, most recently from cac564a to 1ec42ba Compare February 22, 2024 18:48
Previously, our test harness for `TryFromBytes` types assumed that those
types also implemented `NoCell`. This commit introduces machinery that
allows us to conditionally execute certain steps of our tests depending
on whether or not the type under test implements `NoCell`.

This commit also lifts the `T: NoCell` bound in `TryFromBytes for
MaybeUninit<T>` in order to test this machinery.

Makes progress on #5

Co-authored-by: Jack Wrenn <[email protected]>
@joshlf joshlf force-pushed the maybe-uninit-no-cell-try-from-bytes branch from 1ec42ba to e872051 Compare February 22, 2024 18:56
@joshlf joshlf added this pull request to the merge queue Feb 22, 2024
Merged via the queue into main with commit ca49473 Feb 22, 2024
@joshlf joshlf deleted the maybe-uninit-no-cell-try-from-bytes branch February 22, 2024 19:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants