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

Add first-class types for PCSTR and PCWSTR #1550

Merged
merged 10 commits into from
Feb 18, 2022
Merged

Add first-class types for PCSTR and PCWSTR #1550

merged 10 commits into from
Feb 18, 2022

Conversation

kennykerr
Copy link
Collaborator

They're finally here! While the Win32 metadata lacks explicit types for PCSTR and PCWSTR, the metadata gives enough clues as to when they would have existed in the original APIs and my metadata crate now reconstructs that type information. As a result, the windows and windows-sys crates can now offer first-class PCSTR and PCWSTR types, alongside PSTR and PWSTR, thus making const-correct Win32 programming far more natural in Rust.

As these types are synthesized and highly specialized, I've moved them into the windows::core and windows_sys::core modules respectively.

Fixes #1496, fixes #1504

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.

windows-sys doesn't distinguish between LPCWSTR and LPWSTR GetClassNameW function argument mutability
1 participant