[Mono-list] va_list in DllImport

Dietmar Maurer dietmar@ximiam.com
25 Jun 2002 09:26:17 +0200

On Tue, 2002-06-25 at 08:23, Rachel Hestilow wrote:
> If I wanted to DllImport a function that accepted a va_list parameter
> (function gnome_program_initv, in this case), how would I express that
> parameter in C#? The only comparable construct in C# would seem to be
> object[], but I'm not sure if that provides enough information for the
> runtime to marshal everything correctly.
> Alternately, does DllImport support marshalling varargs functions
> directly? (so I could use gnome_program_init instead of
> gnome_program_initv). Either one would work for my purposes.

C# has vararg support: see mono/mono/tests/vararg.cs. But I am not sure
if that works with DllImport an it is currently not supported by mono.

- Dietmar