mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-16 19:39:20 +02:00
+ added defutil.is_32bit helper function, similar to is_64bit
git-svn-id: branches/i8086@23869 -
This commit is contained in:
parent
edd4c1ce4b
commit
a274e62724
@ -228,6 +228,9 @@ interface
|
||||
{# Returns true, if def is a 32 bit integer type }
|
||||
function is_32bitint(def : tdef) : boolean;
|
||||
|
||||
{# Returns true, if def is a 32 bit ordinal type }
|
||||
function is_32bit(def : tdef) : boolean;
|
||||
|
||||
{# Returns true, if def is a 64 bit integer type }
|
||||
function is_64bitint(def : tdef) : boolean;
|
||||
|
||||
@ -794,6 +797,11 @@ implementation
|
||||
result:=(def.typ=orddef) and (torddef(def).ordtype in [u32bit,s32bit])
|
||||
end;
|
||||
|
||||
{ true, if def is a 32 bit ordinal type }
|
||||
function is_32bit(def: tdef): boolean;
|
||||
begin
|
||||
result:=(def.typ=orddef) and (torddef(def).ordtype in [u32bit,s32bit,pasbool32,bool32bit])
|
||||
end;
|
||||
|
||||
{ true, if def is a 64 bit int type }
|
||||
function is_64bitint(def : tdef) : boolean;
|
||||
|
Loading…
Reference in New Issue
Block a user