On 8/6/2010 11:24, bill lam wrote:
> Птн, 06 Авг 2010, David Mitchell писал(а):
>>
>>
>> On 8/6/2010 10:40, bill lam wrote:
>>> Птн, 06 Авг 2010, David Mitchell писал(а):
>>>> gij=: '"c:\users\me\documents\visual studio
>>>> 2010\Projects\Gijswijt\Release\Gijswijt.dll" ?gij@@yaxh...@z +n i *c'&cd
>>> I guess you may add extern "C" to prevent mangled names.
>>>
>>
>> Perhaps there are more changes required. I had tried
>>
>> extern "C" void gij(int nm, char *a) {
>>
>> and the DLL no longer showed any external definition for the function gij.
>>
>> And, as expected, I could not call the function from J.
>>
>> --
>> David Mitchell
>
> Did you export the function? There is an example in j under folder
> examples/dllwrite
>
Thanks, the .def file fixed it (Updated ijs)
gij=: '"c:\users\me\documents\visual studio
2010\Projects\Gijswijt2\Release\Gijswijt2.dll" gij +n i *c'&cd
For me, it's a tossup if it is easier to just use the mangled name or to create
and link with the .def file.
--
David Mitchell
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm