Jonathan Pryor wrote:
On Mon, 2005-10-17 at 19:03 +0200, Florian Weimer wrote:
Why are UTF-16 strings used in Mono.Unix?  Doesn't this mean that some
resources are inaccessible to programs running under Mono in a
multibyte localeq (such as one using UTF-8)?

Care to elaborate?  System.String is always used to represent strings in
Mono.Unix and Mono.Unix.Native, but Mono's marshaler will convert the
strings to UTF-8 for the P/Invoke call.

A peek at Mono.Unix/UnixMarshal.cs hints that managed strings are
marshalled to/from the locale encoding (assuming Encoding.Default is the
locale encoding); so locales other than UTF-8 ought to also work.

Florian, for some background on how CLI/.NET/Mono code interfaces to
native code, and specifically how paramters of various types are handled
see:
http://www.mono-project.com/Interop_with_Native_Libraries

-- brion vibber (brion @ pobox.com)

Attachment: signature.asc
Description: OpenPGP digital signature

_______________________________________________
Mono-list maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-list

Reply via email to