[fpc-devel] new string - question on usage

Hans-Peter Diettrich DrDiettrich1 at aol.com
Wed Oct 12 12:13:31 CEST 2011


Paul Ishenin schrieb:
> 12.10.2011 16:03, Michael Schnell wrote:
>> I suppose a variable of the type "String" is pre-loaded with the
>> predefined "System" encoding ID.
> 
> If you mean "AnsiString" then it is loaded with encoding 0 which means 
> default system codepage. It will get the real encoding number after the 
> first assignment.

Delphi allows for RawByteStrings with encoding 0. When assigned to an 
AnsiString, the string encoding still is zero, both variables seem to 
point to the same string data.

DoDi




More information about the fpc-devel mailing list