-
Notifications
You must be signed in to change notification settings - Fork 516
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
Standalone code generation depends on extension types and functions #2517
Comments
Sure, I can do that - have you tested with the latest version on github to ensure that it meets your needs, and the resulting bindings work as needed? |
Trying it out now |
What's missing: at least
Those methods are not generated by the Also, in the documentation, the need to have |
I'm using commit 72e9bf4 to test, if you push changes I can easily update and retest as needed :) |
Currently those extensions, like the |
It makes bindings impossible to compile for non-sys versions because they're used in the produced bindings |
A minimal repro would be appreciated to help me understand what you're trying to achieve. The standalone code generation is still pretty experimental compared with the |
I'll push the sysinfo branch |
Thanks, the minimal repro involves generating bindings for |
windows-bindgen
As mentioned in #1720 (comment) the standalone bindings should include pretty much everything from the extension file (e.g. https://github.com/microsoft/windows-rs/blob/78a0dbea48f856b03f3e7e650e0e385047d8a10b/crates/tools/riddle/src/rust/extensions/mod/Win32/Foundation/BOOL.rs), including Not sure if this is still an issue since |
This has been fixed now, I tried it with windows-bindgen 0.51.1 (the codegen docs are way outdated though) |
Thanks for following up @poliorcetics |
Thanks for fixing it ! |
Yup, looks to be fixed indeed 👍 |
Hmm no, this is not true. I'm using the Only this is generated: There's no |
See #2517 (comment) Now that |
@kennykerr ah thanks, I've overlooked that.
Sure, but only for types that themselves live in |
No. There's no easy fix - that's why I'm generally cautious about adding handwritten extensions. |
In recent commits (those after
windows-bindgen
0.49), thestandalone
function is now able to handleTypeKind::Class
andTypeKind:: Interface
whereas it wasunimplemented!()
before.I will need those for GuillaumeGomez/sysinfo#950
Not particularly urgent but IIRC releases are done on request for the crates here ?
The text was updated successfully, but these errors were encountered: