Subject:
[ruby-ffi] Basic question about types
From:
Gimi
Date:
10/19/09 9:10 PM
To:
ruby-ffi


Hi all,

I'm new to FFI, and I have a basic question about types. Assume there
is some C code like this:
# -- C code begin --
#if some situation
typedef sometype unsignedint
#else
typedef sometype int
#endif

void some_function(sometype);
#-- C code end --

So I mean when the types of parameters of a function are different in
different situations, how do I write the Ruby code?

Any help will be greatly appreciated.

Regards,