Summary on Re: [fpc-pascal] Unicode file routines proposal

Martin Schreiber fpmse at bluewin.ch
Tue Jul 1 17:50:43 CEST 2008


On Tuesday 01 July 2008 17.06:34 Florian Klaempfl wrote:
> Michael Van Canneyt wrote:
> > On Tue, 1 Jul 2008, Paul Ishenin wrote:
> >> Michael Van Canneyt wrote:
> >>> You can still do C:=S[i]. What you cannot do is
> >>>
> >>>   P:=PChar(S);
> >>>   While (P^<>#0) do
> >>>    SomeByteSizedOperation;
> >>
> >> Why you cannot? PChar(S) should represent S as raw bytes. If you know
> >> what you are doing - it will not harm. In other case, if you corrupt the
> >> string then you are responsibile for all problems you get.
> >
> > Obviously you can :-)
> > But what I meant was that you shouldn't expect old code
> > that relied on 1-byte characters to work.
>
> It is supposed to break on utf-xx or whatever anyways.

Would this new multiencoding string replace a reference counted widestring 
type on Windows?
I'd like to repeat the need for a "as fast as possible" (reference counted)  
widestring on all platforms which offers all possibilities of optimized low 
level pointer stuff like widestrings on Linux, which are ideal for MSEgui 
unicode handling.

Martin



More information about the fpc-pascal mailing list