-
Notifications
You must be signed in to change notification settings - Fork 525
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 support for calling conventions #1999
Conversation
As expected, the build failed the gnu test of |
I haven't looked at the symbol names in detail, but this also fixes #1964 (comment) |
Haven't finished looking, but so far, I found that |
Yup can confirm that. |
There are a lot more now cdecl that aren't in the real DLLs (probably incomplete list):
|
Oh, I just noticed there are some
|
Created microsoft/win32metadata#1217 - hopefully @sotteson1 can take a quick look but at a glance I do agree that this metadata is no good as is. |
These all looks like win32metadata bugs where the signatures are improperly declared, mixing 32 bit and 64 bit integer types. For example, the win32metadata uses enums like I wish the win32metadata could just validate this against the lib files in the SDK using dumpbin. I'll create a win32metadata issue for this. |
So we have the following two new win32metadata issues blocking the adoption of calling convention support and publishing accurate import libs: microsoft/win32metadata#1217 I think I'll just disable the calling convention support for now (so that everything appears to use |
|
@glandium Good catch, we'll generate fresh ones tomorrow. We might be regenerating again anyway w/ some big incoming metadata changes. |
Yes, I'm just waiting for another win32 metadata update since what we have right now is broken anyway. |
Following on #1996 that introduced win32 metadata capturing calling conventions, this update adds support for translating that metadata into Rust bindings. It also corrects a few issues with calculating the
stdcall
stack size requirements. It now correctly takes into account padding and alignment.Fixes #1985