On 03.01.2014 20:53, Graeme Geldenhuys wrote:
On 2014-01-02 00:06, Marco van de Voort wrote:
Why that? Why not simply a variable length string?
Because I was under the impression a ShortString (eg: String[4]
declaration) is faster than AnsiString, and lighter on resources.
This might bite you with 2.7.1 as ShortString is considered as being
encoded in CP_ACP. Thus on systems were the system code page is not
UTF-8, but the values are UTF-8 characters this might lead to unexpected
conversions if you assign to an UTF8String or UnicodeString, because the
compiler will insert a conversion from CP_ACP to
UTF8String/UnicodeString which will convert your UTF8 character to
something completely different.
Regards,
Sven
--
_______________________________________________
Lazarus mailing list
[email protected]
http://lists.lazarus.freepascal.org/mailman/listinfo/lazarus