Le mercredi 08 juillet 2015 à 03:28 -0700, Panagiotis Mamatsis a écrit
 :
> Hello to everyone,
>    i am a n00b in Julia language and i am trying to understand the 
> way to call code written in C via shared libraries. I have started 
> with a 'small scale' case into which i am trying to call a function 
> which returns void but accepts a pointer to an Integer. When i 
> perform the call from a Julia script the number returned back is "0" 
> and not the one i am expecting...when i am calling the C function the 
> argument i am supplying is Ptr{Cint}. Can somebody please explain 
> what i am missing ?
Showing the code you tried would be helpful.

Anyway, this precise case is documented. Let us know whether that's
enough to fix your problem. For 0.3:
http://docs.julialang.org/en/release-0.3/manual/calling-c-and-fortran
-code/#passing-pointers-for-modifying-inputs

For 0.4 (a bit different):
http://docs.julialang.org/en/latest/manual/calling-c-and-fortran
-code/#passing-pointers-for-modifying-inputs


Regards

Reply via email to