[Mono-list] Wrapping a native library which uses "unsigned long" on 32 bit and 64 bit systems

Mathias Tausig mathias.tausig at a-cert.at
Thu Mar 25 05:17:41 EDT 2010


Hello!

I am writing a wrapper for a c library which uses the c datatype
"unsigned long" a lot. According to
http://www.mono-project.com/Interop_with_Native_Libraries , unsigned
long maps to the .NET type uint on a 32bit architecture and to ulong on
a 64-bit one.
Is there some sort of best practice, for achieving to write a library
which can work on both architectures?

cheers
Mathias


More information about the Mono-list mailing list