[fpc-devel] Unicode and UTF8String

Florian Klaempfl florian at freepascal.org
Tue Dec 2 10:32:10 CET 2008


Michael Schnell schrieb:
> 
>> Don't forget that the ansistring type is actually multiple encodings and
>> even multi byte (even not considering UTF-8). The point is: nobody took
>> care of it.
>>   
> IMHO a major confusion is generated by calling a string that is supposed
> to hold UTF8 data "ANSIString". This never should have happened ! 

Nobody talks in this case about UTF-8. Even *ANSIstrings* in there
native meaning can contain multi byte chars, there are *multi byte* ansi
char sets. However, everybody codes 1 char=1 byte when using ansistrings
which is plainly wrong. Guess why Delphi has functions like
CharToByteIndex or NextCharIndex.



More information about the fpc-devel mailing list