We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
The extern functions declared here are all marked as the following: (In C#)
extern
[DllImport("dll_name")] private static extern ret name(params object parameters);
Which is incorrect with respect to the calling convention.
The default ABI for rust extern functions is defined as follows:
By default external blocks assume that the library they are calling uses the standard C ABI on the specific platform.
And as defined here:
// Declares an extern fn, the ABI defaults to "C" extern fn new_i32() -> i32 { 0 }
And in the MS docs pages:
The default value for the CallingConvention field is Winapi, which in turn defaults to StdCall convention.
Therefore the C# code should change to the following:
C#
[DllImport("dll_name", CallingConvention = CallingConvention.Cdecl)] private static extern ret name(params object parameters);
Thank you for your time.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
The
extern
functions declared here are all marked as the following: (In C#)Which is incorrect with respect to the calling convention.
The default ABI for rust
extern
functions is defined as follows:And as defined here:
And in the MS docs pages:
Therefore the
C#
code should change to the following:Thank you for your time.
The text was updated successfully, but these errors were encountered: