[fpc-pascal] Strange message about mixed signed expression

Sven Barth pascaldragon at googlemail.com
Wed Jan 22 19:32:12 CET 2014


On 22.01.2014 19:00, Jürgen Hestermann wrote:
>
> Am 2014-01-22 07:41, schrieb leledumbo:
>> Jürgen Hestermann wrote
>>> Realy?
>>> But why that?
>>> It cannot be negative.
>>> Using integer instead of unsigned values reduces the possible (positive)
>>> range
>>> and produces such illogical (to me) compiler warnings.
>> Delphi compatibility and maximum data size limitation AFAIK (2 GB).
>>
>
> Sigh... all the bad things in FPC crept in from Delphi it seems...
>
> Why did they artifically limit the max number of array elements to 2^31when
> it would have been very easy to have a maximum of 2^32 instead?

You have to think back at that time. 64-bit was in the far future, on 
Windows you only had 2 GB RAM available to user mode (the 3GB switch was 
added with XP AFAIK). So you *could not* allocate more than 2 GB of RAM 
even if you wanted to. And you couldn't even reach that, because you 
still have other memory in use by the RTL.

The rest is history...

Regards,
Sven



More information about the fpc-pascal mailing list