[fpc-pascal] Weird string behavior
Jonas Maebe
jonas.maebe at elis.ugent.be
Tue Jul 26 11:01:28 CEST 2016
Mattias Gaertner wrote on Tue, 26 Jul 2016:
> On Mon, 25 Jul 2016 23:23:23 +0200
> Jonas Maebe <jonas.maebe at elis.ugent.be> wrote:
>
>> Thanks. So the rule for concatenation appears to be:
>> * the dynamic code page of the result of a string concatenation is that
>> of the left operand (except if it's an empty string, then it's that of
>> the right operand)
>> * the declared code page of the final concatenation result is that of
>> the left operand
>
> Here are some more hints:
Could you try the same program with u1 as plain ansistring instead of
utf8string? (with an additional
"setcodepage(rawbytestring(u1),65001,false);" after assigning u1)
Thanks,
Jonas
More information about the fpc-pascal
mailing list