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

windows-bindgen output ordering #3303

Closed
kennykerr opened this issue Sep 30, 2024 · 3 comments · Fixed by #3359
Closed

windows-bindgen output ordering #3303

kennykerr opened this issue Sep 30, 2024 · 3 comments · Fixed by #3359
Labels
enhancement New feature or request

Comments

@kennykerr
Copy link
Collaborator

kennykerr commented Sep 30, 2024

I'm busy revamping windows-bindgen to deal with a number of issues and make it a lot more flexible.

One potential issue is whether we still need to sort function declarations by exporting library to avoid Rust compiler inefficiencies.

@ChrisDenton do you happen to know if that's still an issue with raw-dylib?

I'll probably still need to support some version of this for windows-sys generation, at least for now.

@kennykerr kennykerr added the enhancement New feature or request label Sep 30, 2024
@ChrisDenton
Copy link
Collaborator

It's not an issue with raw-dylib, fortunately.

@ChrisDenton
Copy link
Collaborator

Oh, btw std no longer requires this when using import libs. Instead it uses #[link(name = "kernel32")] for every import. It then has an empty extern block to list the other import libs.

#[link(name = "advapi32")]
#[link(name = "userenv")]
// etc...
extern "C" {}

This isn't ideal as it requires some (albeit rare) manual curation but it side-steps the problem entirely.

@kennykerr
Copy link
Collaborator Author

That is wonky. 🙂

Hopefully rust-lang/rust#129821 will complete soon and we can get rid of all of this.

@kennykerr kennykerr linked a pull request Dec 2, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants