[BioC] C/C++ function registration mechanism

Holger Fröhlich h.froehlich at dkfz-heidelberg.de
Wed Dec 6 10:26:19 CET 2006


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi all,

has anybody experience with the registration mechanism for C/C++
functions for R?

I have a C function of the form:

void OAWrapper(double* Rpre, int* m, int* n, int *mod, double *res)

which I want to register.
However, when I write

void R_init_GOSim(DllInfo *info){
	R_CMethodDef cMethods[] = {{"OAWrapper", &OAWrapper, 5,
{REALSXP,INTSXP, INTSXP, INTSXP, REALSXP}}, {NULL, NULL, 0}};
	R_registerRoutines(info, cMethods, NULL, NULL, NULL);
}

then R crashes. Has anybody an idea?

Thank you very much

Holger


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFdoy75ZMgwjLrZIMRAu4SAJ9uyUFdMu5Ouk2Zie+696yRXmjyQACgqUcp
yodS/0OaMiF7CQnxM0EWLUE=
=YK6U
-----END PGP SIGNATURE-----



More information about the Bioconductor mailing list