[fpc-devel] FPC 2.3.1 seems a mixed mess with Unicode support

Florian Klaempfl florian at freepascal.org
Tue Sep 15 14:15:02 CEST 2009


Jonas Maebe schrieb:
> 
> On 15 Sep 2009, at 13:53, Graeme Geldenhuys wrote:
> 
>> ian Klaempfl het geskryf:
>>>
>>> Do you use the cwstrings unit? Did you tell the encoding (UTF-8?) to the
>>> compiler? Did you use the UnicodeChar instead of Char?
>>
>>
>> Yes to all, and the example still doesn't work.
   ^^^^^^^^^^

>>
>> ------------------------
>> $ ./test3
>> ä
>> ------------------------
>>
>> ä  is not 世 as the website described the result to be.
> 
> That's because you did not specify the code page of the source code, in
> which case it's parsed as CP 8859-1. Add {$codepage utf-8} or save the
> file with an UTF-8 BOM and it will work fine.

Graeme said he did tell the compiler that he uses utf-8.



More information about the fpc-devel mailing list