Skip to content
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

Follow up to switch to windows-sys #1558

Closed
2 of 7 tasks
Thomasdezeeuw opened this issue Mar 31, 2022 · 14 comments
Closed
2 of 7 tasks

Follow up to switch to windows-sys #1558

Thomasdezeeuw opened this issue Mar 31, 2022 · 14 comments
Labels
windows Related to the Windows OS.
Milestone

Comments

@Thomasdezeeuw
Copy link
Collaborator

Thomasdezeeuw commented Mar 31, 2022

Based on #1556, in particular this comment: #1556 (review).

@kennykerr
Copy link

These fixes have now been published as part of the 0.35.0 release:

https://github.com/microsoft/windows-rs/releases/tag/0.35.0

@Thomasdezeeuw
Copy link
Collaborator Author

This microsoft/windows-rs#1636 might be a bit of problem, as Mio supports older rustc versions. Does windows-sys give any MSRV guarantees?

@kennykerr
Copy link

It's currently set to 1.56:

https://github.com/microsoft/windows-rs/blob/d3c2f2ca9385a0f03162e33da40dcc350678161d/.github/workflows/build.yml#L52

Previously it was set to 1.46.0, which should still work in theory but cargo doesn't like it when the version is older than what Rust 2021 supports.

@Thomasdezeeuw
Copy link
Collaborator Author

This issue is now blocked on #1562.

@kennykerr
Copy link

0.36.0 has been released and reverts the Rust 2021 adoption meaning that windows-sys is once again supported on Rust 1.46.

@Noah-Kennedy
Copy link

@Thomasdezeeuw in that case I think we should put this back on the table

@Thomasdezeeuw
Copy link
Collaborator Author

Updating to 0.36 in #1569.

I couldn't find the SIO_BSP_* constants although the linked issue is closed, have those been added @kennykerr?

@kennykerr
Copy link

kennykerr commented Apr 27, 2022

I couldn't find the SIO_BSP_* constants although the linked issue is closed, have those been added?

Which one in particular? I see a bunch have been added.

Adding @riverar who may have further insights.

@Thomasdezeeuw
Copy link
Collaborator Author

I couldn't find the SIO_BSP_* constants although the linked issue is closed, have those been added?

Which one in particular? I see a bunch have been added.

I just realised GitHub doesn't have partial search, window-sys actually has all the constants Mio need. Sorry about that

@Thomasdezeeuw Thomasdezeeuw added this to the v1.0 milestone Dec 8, 2023
@Thomasdezeeuw
Copy link
Collaborator Author

After #1688 all that is left are some AFD related types and constants (see updated issue description), so looking pretty good.

@Thomasdezeeuw
Copy link
Collaborator Author

Closing this as done, we can switch to using AFD constants from windows-sys if/when those become available, no point in keeping this open.

@riverar
Copy link

riverar commented Dec 23, 2023

Happy to add those now; just need a pointer to what's missing/needed. Is it just the POLL_xxx constants linked above?

@riverar
Copy link

riverar commented Dec 23, 2023

Ah, I see the others. Will be interesting to get these into metadata, given they're undocumented/"private" structures.

//
// Structures for IOCTL_AFD_POLL.
//

typedef struct _AFD_POLL_HANDLE_INFO {
    HANDLE Handle;
    ULONG PollEvents;
    NTSTATUS Status;
} AFD_POLL_HANDLE_INFO, *PAFD_POLL_HANDLE_INFO;

typedef struct _AFD_POLL_INFO {
    LARGE_INTEGER Timeout;
    ULONG NumberOfHandles;
    BOOLEAN Unique;
    AFD_POLL_HANDLE_INFO Handles[1];
} AFD_POLL_INFO, *PAFD_POLL_INFO;

@Thomasdezeeuw
Copy link
Collaborator Author

Ah, I see the others. Will be interesting to get these into metadata, given they're undocumented/"private" structures.

I suspected as much. I'm happy to keep the definitions in Mio as well.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
windows Related to the Windows OS.
Projects
None yet
Development

No branches or pull requests

4 participants