Re: CWString API

2004-11-30 Thread Krasimir Angelov
--- John Meacham <[EMAIL PROTECTED]> wrote: > Note that in general, there will not ever be a > guarenteed one-to-one > mapping between chars,wchar_ts and haskell Chars, so > higher level > routines must work on strings rather than individual > chars. With other words the case for wchar_t isn't wo

Re: CWString API

2004-11-30 Thread John Meacham
On Tue, Nov 30, 2004 at 02:40:20AM -0800, Krasimir Angelov wrote: > --- John Meacham <[EMAIL PROTECTED]> wrote: > > The problem is that these operations are very > > unsafe, there is no > > guarenteed isomorphism or even injection between > > wchar_ts and Chars. If > > people really know what they

Re: CWString API

2004-11-30 Thread Krasimir Angelov
--- John Meacham <[EMAIL PROTECTED]> wrote: > The problem is that these operations are very > unsafe, there is no > guarenteed isomorphism or even injection between > wchar_ts and Chars. If > people really know what they are doing, they can do > the conversion > themselves via fromIntegral/ord/chr,

Re: CWString API

2004-11-30 Thread John Meacham
On Tue, Nov 30, 2004 at 10:17:13AM -, Simon Marlow wrote: > On 30 November 2004 09:35, John Meacham wrote: > > > On Tue, Nov 30, 2004 at 12:41:04AM -0800, Krasimir Angelov wrote: > >>Hello guys, > >> > >> I am working on updated version of HDirect and now I > >> am going to use CWString A

RE: CWString API

2004-11-30 Thread Simon Marlow
On 30 November 2004 09:35, John Meacham wrote: > On Tue, Nov 30, 2004 at 12:41:04AM -0800, Krasimir Angelov wrote: >>Hello guys, >> >> I am working on updated version of HDirect and now I >> am going to use CWString API to marshal (wchar_t *) >> type to String. I found some inconsistencies in

Re: CWString API

2004-11-30 Thread John Meacham
On Tue, Nov 30, 2004 at 12:41:04AM -0800, Krasimir Angelov wrote: >Hello guys, > > I am working on updated version of HDirect and now I > am going to use CWString API to marshal (wchar_t *) > type to String. I found some inconsistencies in the > API. > - castCWcharToChar and castCharToCWcha