From: Kurt Dresner Date: 2004-11-21T05:03:41+09:00 Subject: SWIG and Arrays (of ints) Hi all, I'm trying to get SWIG to create a wrapper for some C code. Specifically, there are several functions that take, as parameters, an int* (they also take the length of the array). I don't know how to do the typemap for this - I want to be able to write My_module.my_c_function([1,2,3]) for the corresponding C function void my_c_function(int size, int* ary) Additionally, one of the functions takes an integer array as a parameter, and I'd like it instead to return an array in Ruby (full of Nums). I know how to get it to return the argument (instead of doing the pointer passing thing), but then it just thinks I want to pass it an integer instead of an array of integers. Anyone have any idea how to help me? Everything I've seen pertains to char** and I'm not sure how to convert it to work how I want with int*. TIA, Kurt