[fpc-pascal] code example where AnsiString used in FCL (SqlDB) causes data loss

Tomas Hajny XHajT03 at hajny.biz
Wed May 11 22:38:42 CEST 2016


On Wed, May 11, 2016 22:08, Graeme Geldenhuys wrote:
> On 2016-05-11 18:58, Michael Van Canneyt wrote:
>> For 99,99% of cases, no changes to your code are required.
>> If it worked in 2.6.4, it will work in 3.0.0
>
> Just curious, so why was there so many changes required for LCL, and a
> whole wiki page of its own to explain it?

My understanding: Because LCL wanted to benefit from new possibilities in
version 3.0.0 (e.g. use functionality newly provided by the RTL instead of
certain own alternative routines), but the previous LCL code included some
assumptions (like that all ansistrings should always contain UTF-8) which
may not always be the case in FPC RTL by default (e.g. certainly not for
MS Windows applications). But again - they could continue using the
original code as it was if they wanted to do so.

Tomas





More information about the fpc-pascal mailing list