CallConvHack

The main purpose of CallConvHack is to provide a working SubversionSharp to Windows users. Subversion callbacks should use Cdecl calling convention. Under Windows, C# delegates default to Stdcall calling convention. Moreover, there is no way using plain C# to change this behaviour1. This hack (based on several articles, blogs and posts available elsewhere) patch IL code directly to fix the calling convention of attribute-marked delegates.

The originality of our implementation is both the external DLL used to implement the CallConvCdeclAttribute and the C# program that works as a filter to translate the standard output of ildasm.

Statusstable
Releasenot yet packaged
Browse Trunkhttps://github.com/softec/SubversionSharp
LanguageC#
Depends onNothing
LicenseGNU Lesser General Public License (LGPL)
  1. ^ In .NET 2.0 framework, the attribute UnmanagedFunctionPointerAttribute could be use in place of this hack