[Lazarus] Unicode branch

Michael Van Canneyt michael at freepascal.org
Thu Jun 13 11:51:38 CEST 2013



On Thu, 13 Jun 2013, Michael Schnell wrote:

> On 06/13/2013 11:32 AM, Michael Van Canneyt wrote:
>> 
>> And they'll need defines anyway because widestring <> unicodestring on 
>> windows.
>> 
> The compiler does know whether it compiles for Windows or not. Doesn't it ?

The problem is not in the compiler. 
The problem is that IF your code assumes that WideString=UnicodeString
then you will need to differentiate the 2 cases.

You can do this based on the OS define (bad practice, because it encompasses 
an implicit assumption) or introduce a new define (as FPC did).

You can set this new define based on the OS, but this is secondary.

Michael.




More information about the Lazarus mailing list