API Update+Base FASM Support
This commit is contained in:
@@ -23,24 +23,24 @@ var
|
||||
Src:TRTBSource;
|
||||
Func1:TRTBFunc;
|
||||
begin
|
||||
{Fasm:=TRTBFasmCompiler.Create('..\..\..\FasmOnDelphi\fasmw172\fasm');
|
||||
Fasm:=TRTBFasmCompiler.Create('..\..\..\lib\FasmOnDelphi\fasmw172\fasm');
|
||||
Src:=Fasm.GenNewSrc;
|
||||
Src.Text:='use32'+sLineBreak+'pop ecx'+sLineBreak+'pop eax'+sLineBreak+'jmp ecx';
|
||||
Func1:=src.CompilateAsFunc;
|
||||
Src.Text:='use32'+sLineBreak+'main:'+sLineBreak+'pop ecx'+sLineBreak+'pop eax'+sLineBreak+'jmp ecx';
|
||||
Src.RegisterFunction('','main');
|
||||
Func1:=src.Compilate.Funtion['main'];
|
||||
if 454<>Func1.Call(TypeInfo(integer),[454],CRTBCallTypeStdCall).AsInteger then
|
||||
begin
|
||||
raise Exception.Create('Error in test1');
|
||||
end;
|
||||
FreeAndNil(Func1);
|
||||
FreeAndNil(Src);
|
||||
FreeAndNil(Fasm);}
|
||||
FreeAndNil(Fasm);
|
||||
end;
|
||||
|
||||
procedure TRuntimeBuilderTestObject.Test2();
|
||||
var
|
||||
Fasm:TRTBFasmCompiler;
|
||||
Src:TRTBSource;
|
||||
lib:TRTBLib;
|
||||
Func1:TRTBFunc;
|
||||
begin
|
||||
{Fasm:=TRTBFasmCompiler.Create('..\..\..\FasmOnDelphi\fasmw172\fasm');
|
||||
|
||||
Reference in New Issue
Block a user