mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-08 22:47:54 +02:00
* NativeInt and NativeUInt redefined as aliases to PtrInt/PtrUInt, so now they
become 32-bit in some i8086 memory models. Added comment explaining why they were introduced (delphi compatibility) and why they shouldn't be used in the FPC RTL. git-svn-id: trunk@27238 -
This commit is contained in:
parent
fb20791cbe
commit
dfa1f3e0a3
@ -338,8 +338,6 @@ Type
|
||||
PtrUInt = QWord;
|
||||
ValSInt = int64;
|
||||
ValUInt = qword;
|
||||
NativeInt = PtrInt;
|
||||
NativeUint = PtrUint;
|
||||
CodePointer = Pointer;
|
||||
CodePtrInt = PtrInt;
|
||||
CodePtrUInt = PtrUInt;
|
||||
@ -352,8 +350,6 @@ Type
|
||||
PtrUInt = DWord;
|
||||
ValSInt = Longint;
|
||||
ValUInt = Cardinal;
|
||||
NativeInt = PtrInt;
|
||||
NativeUint = PtrUint;
|
||||
CodePointer = Pointer;
|
||||
CodePtrInt = PtrInt;
|
||||
CodePtrUInt = PtrUInt;
|
||||
@ -384,10 +380,18 @@ Type
|
||||
{$endif}
|
||||
ValSInt = Integer;
|
||||
ValUInt = Word;
|
||||
NativeInt = Integer;
|
||||
NativeUint = Word;
|
||||
{$endif CPU16}
|
||||
|
||||
{ NativeInt and NativeUInt are Delphi compatibility types. Even though Delphi
|
||||
has IntPtr and UIntPtr, the Delphi documentation for NativeInt states that
|
||||
'The size of NativeInt is equivalent to the size of the pointer on the
|
||||
current platform'. Because of the misleading names, these types shouldn't be
|
||||
used in the FPC RTL. Note that on i8086 their size changes between 16-bit
|
||||
and 32-bit according to the memory model, so they're not really a 'native
|
||||
int' type there at all. }
|
||||
NativeInt = PtrInt;
|
||||
NativeUInt = PtrUInt;
|
||||
|
||||
Int8 = ShortInt;
|
||||
Int16 = SmallInt;
|
||||
Int32 = Longint;
|
||||
|
Loading…
Reference in New Issue
Block a user