* make procedures and functions, declared in the interface part of a unit in an

i8086 far code memory model to be 'far' even in {$F-} mode. This is TP7
  compatible.

git-svn-id: trunk@38728 -
This commit is contained in:
nickysn 2018-04-10 15:37:28 +00:00
parent 288afbe3b4
commit 17823821ca
2 changed files with 10 additions and 1 deletions

View File

@ -130,6 +130,7 @@ type
- it has no 'near' or 'far' specifiers
- it is compiled in a $F- state }
function default_far:boolean;
procedure Setinterfacedef(AValue: boolean);override;
public
constructor create(level:byte;doregister:boolean);override;
function getcopyas(newtyp:tdeftyp;copytyp:tproccopytyp):tstoreddef;override;
@ -396,6 +397,14 @@ implementation
end;
procedure tcpuprocdef.Setinterfacedef(AValue: boolean);
begin
inherited;
if (current_settings.x86memorymodel in x86_far_code_models) and AValue then
include(procoptions,po_far);
end;
function tcpuprocdef.is_far: boolean;
begin
result:=(po_exports in procoptions) or

View File

@ -742,7 +742,7 @@ interface
function Getforwarddef: boolean;
procedure Setforwarddef(AValue: boolean);
function Getinterfacedef: boolean;
procedure Setinterfacedef(AValue: boolean);
procedure Setinterfacedef(AValue: boolean);virtual;
function Gethasforward: boolean;
procedure Sethasforward(AValue: boolean);
function GetIsEmpty: boolean;