[Lazarus] Feature Request: Insert {codepage UTF8} per default
Maxim Ganetsky
ganmax at narod.ru
Thu Mar 31 01:10:16 CEST 2016
31.03.2016 1:48, Bart пишет:
> On 3/31/16, Graeme Geldenhuys <mailinglists at geldenhuys.co.uk> wrote:
>
>> [~]$ echo $LANG
>> en_GB.UTF-8
>
> This is what I hink is happening to your test (Sven can probably
> explain it better):
>
> Since your locale is UTF8, CP_ACPand CP_UTF8 refer to the same
> codepage, therefor the contents of S1 in either case is correct.
>
> Without the codepage identifiier on Windows, after the assignement S1
> contains a UTF8 byte-sequence, but the compiler treats it as CP_ACP,
> and therefor on my system as codepage 1252, and now the string has a
> completely different meaning.
Lazarus switches DefaultSystemCodePage to 65001, so your example works
OK here without codepage directive (when inserted into LCL dependent
project, of course).
--
Best regards,
Maxim Ganetsky mailto:ganmax at narod.ru
More information about the Lazarus
mailing list