Hi folks.

This may be a bit off topic, but it is ruby related.

I can't seem to get swig to work when my function
has a pointer argument. Here is my simple example:


swig -version

SWIG Version 1.3.9u-20030501-1037
Copyright (c) 1995-1998
University of Utah and the Regents of the University of California
Copyright (c) 1998-2001
University of Chicago

Compiled with CC

cat example.c
int fact2(int *n) {
  return *n *2;
}

 cat example.i
/* example.i */
%module example
%{
/* Put header files here (optional) */
%}

extern int fact2(int *n);


ruby -r example -e 'puts Example.fact2(2)'
-e:1:in `fact2': Expected int * (TypeError)
        from -e:1

Everything looks correct. I see wrapper code
in example_wrap.c that appears to be wrapping
the int * for me, but no worky.

Any suggestions?

Thanks
-- 
Jim Freeze
----------
You know if they ever find a way to harness sarcasm as an energy source,
you people are all going to owe me big.
		-- Bill Paul