[Python.NET] Visual Studio extension to convert [DllImport] into new unmanaged function pointers
Victor Milovanov <[email protected]> Thu, 11 Feb 2021 09:34:37 -0800
| Newsgroups | gmane.comp.python.dotnet |
|---|---|
| Message-ID | <CA+mjbR-1tTJDtMsdtzEyVcdEeKR9w37kpugGRE9PjPAFqsOQ=A@mail.gmail.com> |
--===============0150997130296226130== Content-Type: multipart/alternative; boundary="000000000000aa5e1705bb12efe5" --000000000000aa5e1705bb12efe5 Content-Type: text/plain; charset="UTF-8" OneDrive link: https://1drv.ms/u/s!AioR7aFFo_FKzuwi_AkxqtZj7JnXhw?e=uriiwU This is a custom build of Roslynator You write something like [DllImport(PythonDLL, CallingConvention = CDecl)] public extern void PyProc(); Then VS should offer a refactoring, that converts this to unmanaged pointers. // Victor --000000000000aa5e1705bb12efe5 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable <div dir=3D"ltr"><div>OneDrive link:=20 <a href=3D"https://1drv.ms/u/s!AioR7aFFo_FKzuwi_AkxqtZj7JnXhw?e=3DuriiwU">h= ttps://1drv.ms/u/s!AioR7aFFo_FKzuwi_AkxqtZj7JnXhw?e=3DuriiwU</a></div><div>= <p class=3D"MsoNormal" style=3D"margin:0in;font-size:11pt;font-family:"= ;Calibri",sans-serif"> </p><p class=3D"MsoNormal" style=3D"margin:0in;font-size:11pt;font-family:&= quot;Calibri",sans-serif"></p> <p class=3D"MsoNormal" style=3D"margin:0in;font-size:11pt;font-family:"= ;Calibri",sans-serif"><br><span></span></p> </div><div>This=C2=A0is=C2=A0a=C2=A0custom=C2=A0build=C2=A0of=C2=A0Roslynat= or</div><br>=C2=A0You=C2=A0write=C2=A0something=C2=A0like<br><br>=C2=A0[Dll= Import(PythonDLL,=C2=A0CallingConvention=C2=A0=3D=C2=A0CDecl)]<br>=C2=A0pub= lic=C2=A0extern=C2=A0void=C2=A0PyProc();<br><br>=C2=A0Then=C2=A0VS=C2=A0sho= uld=C2=A0offer=C2=A0a=C2=A0refactoring,=C2=A0that=C2=A0converts=C2=A0this= =C2=A0to=C2=A0unmanaged=C2=A0pointers.<br><br>=C2=A0//=C2=A0Victor</div> --000000000000aa5e1705bb12efe5-- --===============0150997130296226130== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ PythonNet mailing list -- [email protected] To unsubscribe send an email to [email protected] https://mail.python.org/mailman3/lists/pythonnet.python.org/ Member address: [email protected] --===============0150997130296226130==--