Skip to content

Conversation

@cratelyn
Copy link
Contributor

@cratelyn cratelyn commented Feb 13, 2025

this commit introduces a new method to
tokio::sync::oneshot::Receiver<T>.

this method returns true if the channel is closed. this is similar to the existing
tokio::sync::mpsc::UnboundedReceiver::is_closed() and tokio::sync::mpsc::Receiver::is_closed() methods.

see:

this commit introduces a new method to
`tokio::sync::oneshot::Receiver<T>`.

this method returns true if the channel is closed.

this is similar to the existing
`tokio::sync::mpsc::UnboundedReceiver::is_closed()` and
`tokio::sync::mpsc::Receiver::is_closed()` methods.

see:
* https://docs.rs/tokio/latest/tokio/sync/mpsc/struct.Receiver.html#method.is_closed
* https://docs.rs/tokio/latest/tokio/sync/mpsc/struct.UnboundedReceiver.html#method.is_closed
* tokio-rs#7137 (comment)

Signed-off-by: katelyn martin <[email protected]>
@github-actions github-actions bot added the R-loom-sync Run loom sync tests on this PR label Feb 13, 2025
@cratelyn
Copy link
Contributor Author

there are still some open questions about the semantics of this method. see in particular, this thread of discussion from #7137.

@cratelyn
Copy link
Contributor Author

i see issues in ci at the moment, but i am marking this as ready for review because i believe these errors to be unrelated.

⚠️ Failed to start an instance: INVALID_ARGUMENT: Not Found 404 Not Found
POST [https://compute.googleapis.com:443/compute/v1/projects/cirrus-ci-community/zones/us-central1-c/instances](https://compute.googleapis.com/compute/v1/projects/cirrus-ci-community/zones/us-central1-c/instances)
@cratelyn cratelyn marked this pull request as ready for review February 13, 2025 20:52
@Darksonn Darksonn added A-tokio Area: The main tokio crate M-sync Module: tokio/sync labels Feb 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

A-tokio Area: The main tokio crate M-sync Module: tokio/sync R-loom-sync Run loom sync tests on this PR

3 participants