[fpc-devel] Just need to double check the size of Integer
Tomas Hajny
XHajT03 at hajny.biz
Thu Nov 24 14:24:38 CET 2022
On 2022-11-24 14:13, J. Gareth Moreton via fpc-devel wrote:
Hi Kit,
> I just need to double-check something. Under CPU16, SizeInt and
> SizeUInt are declared as follows:
>
> SizeInt = Integer;
> SizeUInt = Word;
>
> Is Integer 16-bit in this case? I always thought Integer was defined
> as a signed 32-bit integer under FreePascal. Or is this a bug with
> rtl/inc/systemh.inc and it should be defined as SmallInt instead?
You're wrong. The size of Integer depends on the compilation mode. It is
16-bit in the TP and FPC modes, but overridden to 32-bit in OBJPAS and
DELPHI modes.
Tomas
More information about the fpc-devel
mailing list