Skip to content

Commit

Permalink
feat: Add support for waiting on waitable handles
Browse files Browse the repository at this point in the history
* Add support for polling waitable handles

* Add a smoke test

* Fix failing tests

* Rebase on latest master

Signed-off-by: John Nunley <[email protected]>

* Update semantics for new system

Signed-off-by: John Nunley <[email protected]>

* Forgot about doctests

Signed-off-by: John Nunley <[email protected]>

---------

Signed-off-by: John Nunley <[email protected]>
  • Loading branch information
notgull authored Aug 9, 2023
1 parent 6d13def commit c6a0890
Show file tree
Hide file tree
Showing 6 changed files with 724 additions and 57 deletions.
1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ version = "0.48"
features = [
"Win32_Foundation",
"Win32_Networking_WinSock",
"Win32_Security",
"Win32_Storage_FileSystem",
"Win32_System_IO",
"Win32_System_LibraryLoader",
Expand Down
3 changes: 3 additions & 0 deletions src/iocp/afd.rs
Original file line number Diff line number Diff line change
Expand Up @@ -536,6 +536,9 @@ impl<T: fmt::Debug> fmt::Debug for IoStatusBlock<T> {
}
}

unsafe impl<T: Send> Send for IoStatusBlock<T> {}
unsafe impl<T: Sync> Sync for IoStatusBlock<T> {}

impl<T> From<T> for IoStatusBlock<T> {
fn from(data: T) -> Self {
Self {
Expand Down
Loading

0 comments on commit c6a0890

Please sign in to comment.