[Mono-list] How to pass arrays from C to embedded Mono?

Robert Jordan robertj at gmx.net
Sat Nov 18 07:52:43 EST 2006

Hugh Perkins wrote:
> How can arrays be passed from C into embedded Mono?

The best way is either to create a MonoArray* (see mono_array_new)
and fill (see the mono_array_* accessors or the vector member)
on the C side, or to create the array in managed code and fill it
on the C side again.

The MonoArray* can be passed like an object (since it is one)
to mono_runtime_invoke or to a delegate ftnptr.


More information about the Mono-list mailing list