Micha Nelissen wrote:
> On Thu, 22 Sep 2005 16:52:18 +0200
> Bogus�aw Brandys <[EMAIL PROTECTED]> wrote:
>
>
>>Hi,
>>
>>
>>I'm trying to compile REMObject pascal script under FPC + Lazarus (for
>>GUI classes)
>>I encounter strange problem.
>
>
> I encounter strange code :-P.
>
>
>>type
>> TMyRunLine = procedure(Self: TPSExec);
>
>
> Using "Self" as parameter name ? Self is a keyword, this is a bad idea.
>
>
>>function GetRunLine(FOnRunLine: TPSOnLineEvent; meth: TPSRunLine):
>>TMyRunLine;
>>begin
>> OutputdebugString('Inside GetrunLine');
>> if (TMethod(Meth).Code = @TPSExec.RunLine) and (@FOnRunLine = nil) then
>> Result := nil
>> else
>> Result := TMethod(Meth).Code;
>>end;
>>
>>(..)
>>
>>var
>>FOnrunLine : TMyRunLine;
>>begin
>> CallRunLine := GetRunLine(FOnRunLine,Self.RunLine);
>
>
> FOnRunLine is not initialized, you're passing garbage.
>
> Micha
>
>
>> repeat
>> FStatus := isRunning;
>>// Cmd := InvalidVal;
>> while FStatus = isRunning do
>> begin
>> if @CallRunLine <> nil then CallRunLine(Self);
>> if FCurrentPosition >= FDataLength then
>> begin
>> CMD_Err(erOutOfRange); // Error
>> break;
>> end;
>>// if cmd <> invalidval then ProfilerExitProc(Cmd+1);
>
>
TMyRunLine = procedure(XSelf: TPSExec);
is not working eighter.
Regards
Boguslaw Brandys
_________________________________________________________________
To unsubscribe: mail [EMAIL PROTECTED] with
"unsubscribe" as the Subject
archives at http://www.lazarus.freepascal.org/mailarchives