-
Notifications
You must be signed in to change notification settings - Fork 17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement Send
for chunk types
#78
Conversation
This clippy error is really weird
|
Yeah, that's strange. Interestingly, this lint is not triggered by #75. |
Rust 1.58.1 has been released, I've restarted CI and now it passes. |
@@ -444,6 +444,8 @@ pub struct WriteChunkUninit<'a, T> { | |||
producer: &'a Producer<T>, | |||
} | |||
|
|||
unsafe impl<T: Send> Send for WriteChunkUninit<'_, T> {} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What about adding a comment regarding safety?
Maybe something like this:
// WriteChunkUninit only exists while a unique reference to the Producer is held.
// It is therefore safe to move it to another thread.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've added comments as suggestions, what do you think about them?
Co-authored-by: Matthias Geier <[email protected]>
#4