From 65a9885885afeb2c5656ec4e47fe26a1050571aa Mon Sep 17 00:00:00 2001 From: nickysn Date: Tue, 4 Oct 2016 13:40:02 +0000 Subject: + added types sizesinttype and sizeuinttype, corresponding to the SizeInt and SizeUInt types for the target platform git-svn-id: http://svn.freepascal.org/svn/fpc/trunk@34619 3ad0048d-3df7-0310-abae-a5850022a9f2 --- compiler/psystem.pas | 8 ++++++++ compiler/symdef.pas | 3 +++ 2 files changed, 11 insertions(+) diff --git a/compiler/psystem.pas b/compiler/psystem.pas index 7af3ea5449..2e50f666d4 100644 --- a/compiler/psystem.pas +++ b/compiler/psystem.pas @@ -115,10 +115,14 @@ implementation procedure set_default_int_types; begin {$ifdef cpu64bitaddr} + sizeuinttype:=u64inttype; + sizesinttype:=s64inttype; uinttype:=u64inttype; sinttype:=s64inttype; {$endif cpu64bitaddr} {$ifdef cpu32bitaddr} + sizeuinttype:=u32inttype; + sizesinttype:=s32inttype; uinttype:=u32inttype; sinttype:=s32inttype; {$endif cpu32bitaddr} @@ -126,6 +130,10 @@ implementation uinttype:=u32inttype; sinttype:=s32inttype; {$endif cpu32bitalu} +{$ifdef cpu16bitaddr} + sizeuinttype:=u16inttype; + sizesinttype:=s16inttype; +{$endif cpu16bitaddr} {$ifdef cpu16bitalu} uinttype:=u16inttype; sinttype:=s16inttype; diff --git a/compiler/symdef.pas b/compiler/symdef.pas index 7dbebbf6eb..eb11e9337f 100644 --- a/compiler/symdef.pas +++ b/compiler/symdef.pas @@ -1072,6 +1072,9 @@ interface { integer types corresponding to OS_SINT/OS_INT } ossinttype, osuinttype, + { integer types corresponding to SizeInt and SizeUInt for the target platform } + sizeuinttype, + sizesinttype, { unsigned and signed ord type with the same size as a pointer } ptruinttype, ptrsinttype, -- cgit v1.2.1