|
@@ -26,7 +26,7 @@ unit njvmmat;
|
|
interface
|
|
interface
|
|
|
|
|
|
uses
|
|
uses
|
|
- node,nmat,ncgmat;
|
|
|
|
|
|
+ node,nmat,ncgmat,ncghlmat;
|
|
|
|
|
|
type
|
|
type
|
|
tjvmmoddivnode = class(tmoddivnode)
|
|
tjvmmoddivnode = class(tmoddivnode)
|
|
@@ -40,9 +40,7 @@ interface
|
|
procedure pass_generate_code;override;
|
|
procedure pass_generate_code;override;
|
|
end;
|
|
end;
|
|
|
|
|
|
- tjvmnotnode = class(tcgnotnode)
|
|
|
|
- function pass_1: tnode; override;
|
|
|
|
- procedure second_boolean;override;
|
|
|
|
|
|
+ tjvmnotnode = class(tcghlnotnode)
|
|
end;
|
|
end;
|
|
|
|
|
|
tjvmunaryminusnode = class(tcgunaryminusnode)
|
|
tjvmunaryminusnode = class(tcgunaryminusnode)
|
|
@@ -187,35 +185,6 @@ implementation
|
|
end;
|
|
end;
|
|
|
|
|
|
|
|
|
|
-{*****************************************************************************
|
|
|
|
- tjvmnotnode
|
|
|
|
-*****************************************************************************}
|
|
|
|
-
|
|
|
|
- function tjvmnotnode.pass_1: tnode;
|
|
|
|
- begin
|
|
|
|
- result:=inherited;
|
|
|
|
- if not assigned(result) and
|
|
|
|
- is_boolean(resultdef) then
|
|
|
|
- expectloc:=LOC_JUMP;
|
|
|
|
- end;
|
|
|
|
-
|
|
|
|
-
|
|
|
|
- procedure tjvmnotnode.second_boolean;
|
|
|
|
- var
|
|
|
|
- hl : tasmlabel;
|
|
|
|
- begin
|
|
|
|
- hl:=current_procinfo.CurrTrueLabel;
|
|
|
|
- current_procinfo.CurrTrueLabel:=current_procinfo.CurrFalseLabel;
|
|
|
|
- current_procinfo.CurrFalseLabel:=hl;
|
|
|
|
- secondpass(left);
|
|
|
|
- hlcg.maketojumpbool(current_asmdata.CurrAsmList,left);
|
|
|
|
- hl:=current_procinfo.CurrTrueLabel;
|
|
|
|
- current_procinfo.CurrTrueLabel:=current_procinfo.CurrFalseLabel;
|
|
|
|
- current_procinfo.CurrFalseLabel:=hl;
|
|
|
|
- location.loc:=LOC_JUMP;
|
|
|
|
- end;
|
|
|
|
-
|
|
|
|
-
|
|
|
|
{*****************************************************************************
|
|
{*****************************************************************************
|
|
tjvmunaryminustnode
|
|
tjvmunaryminustnode
|
|
*****************************************************************************}
|
|
*****************************************************************************}
|