[R] Problem with .C

Grigory Alexandrovich alexandrovich at mathematik.uni-marburg.de
Tue Oct 4 14:04:02 CEST 2011


Hello,

I wrote a function in C, which works fine if called from the 
main-function in C.

But as soon as I try to call this function from R like .C('foo', 
as.double(x), as.integer(y)), the programm crashes.

I created a dll with the cmd command R --arch x64 CMD SHLIB foo.c and 
loaded it into R with dyn.load().

What can be the cause of such behaviour?
Again, the C-funcion itself works, but not if called from R.

Thanks
Grigory Alexandrovich



More information about the R-help mailing list