From: Jano Svitok Date: 2007-12-18T01:34:42+09:00 Subject: Re: SWIG function problem On Dec 16, 2007 10:53 AM, Fla As wrote: > And I try to write the next-function in c > float gen_random(int *last, float max, int IM, int IA, int IC) { > *last = (*last * IA + IC) % IM; > return (max * *last / (float)IM); > } > and with help SWIG I try make useable in Ruby but I can not. See http://www.swig.org/Doc1.3/Ruby.html#Ruby_nn32 (you can reuse your original header if you #ifdef swig directives, see swig doc for more info). If that doesn't help, please post somewhere your code, including ruby, c, and swig header. It would make reproducing your problem easier. J.