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

Bug: microsoft document and crates.io out of date #2583

Closed
ghost opened this issue Jul 25, 2023 · 2 comments
Closed

Bug: microsoft document and crates.io out of date #2583

ghost opened this issue Jul 25, 2023 · 2 comments
Labels
question Further information is requested

Comments

@ghost
Copy link

ghost commented Jul 25, 2023

Which crate is this about?

other (please share in the comments)

Crate version

No response

Summary

i can't find Transform BOOL and Win32 return values #2476 in microsoft document

Toolchain version/configuration

No response

Reproducible example

No response

Crate manifest

No response

Expected behavior

No response

Actual behavior

No response

Additional comments

No response

@ghost ghost added the bug Something isn't working label Jul 25, 2023
@tim-weis
Copy link
Contributor

The latest version of the windows crate (0.48.0) was released on March 31st, 2023. PR #2476 was merged on April 26th, 2023.

In other words: The BOOL/last error code -> Result<()> transformation hasn't been published yet, and the documentation properly reflects the latest published version of the windows crate.

@kennykerr kennykerr added question Further information is requested and removed bug Something isn't working labels Jul 25, 2023
@tim-weis
Copy link
Contributor

It's not clear from the issue what the goal is.

If you just want to take advantage of the convenience introduced by PR #2476, you can specify a git repository dependency in your Cargo.toml, something like this:

[dependencies.windows]
git = "https://github.com/microsoft/windows-rs.git"
rev = "refs/pull/2476/head"
features = []

The rev table entry isn't strictly required. It locks the dependency on the specific PR that introduced this feature. It can be omitted if that is not something you need.

That works1, as long as you aren't planning to publish a crate with this dependency through crates.io. If you are, you'll need to request a new release, which would also update the documentation to align with the published artifacts.

Footnotes

  1. If you are fine writing code against an interface that doesn't match the published documentation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants