[fpc-pascal] FPC vs Delphi's unicode string support questions

Graeme Geldenhuys graemeg.lists at gmail.com
Sun Aug 19 00:44:26 CEST 2012


On 18 August 2012 22:50, Jonas Maebe <jonas.maebe at elis.ugent.be> wrote:
> If you don't want this code page behaviour anyway, you can use the following
> {$mode delphiunicode}
> {$modeswitch systemcodepage-}

OK, I think I got my final answer on this.... FPC is definitely not
ready to port any Delphi 2009+ projects. I fix one error, and get 30+
new errors.... over and over... The RTL _must_ also be unicode aware
for any delphi unicode project to be ported. For example, you can't
currently do something as simple as defining your own exception
classes based on the RTL's Exception class, because the FPC 2.7.1 RTL
defines the Message property as AnsiString at the moment, and doing a
UnicodeString to AnsiString conversion will give you data loss. This
is a critical issue, and appears all over the RTL at the moment.

So for anybody thinking of trying what I did...... DON'T BOTHER AT THIS TIME.

But thanks to everybody that offered information on this... it was
educational. :-)

  - Graeme -

fpGUI - a cross-platform Free Pascal GUI toolkit

More information about the fpc-pascal mailing list