[lazarus] Yes I didn't stop yet
Michael A. Hess
mhess at miraclec.com
Wed Jul 7 23:42:26 EDT 1999
Shane I made a test program using Dispatch. Don't try and use it yet it
appears to have problems. If I only define one procedure with a message
it works fine. If I try to define a second one the compiler panics with
a 9999 error.
For the FPC guys here is what blows. This gives and internal error 9999
and indicates it occurs at the 'end;' statement of the class definition.
Now if comment out the second message and anything to do with DoClick2
the program compiles and works correctly.
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++===
program msgtest;
{$mode delphi}
uses sysutils;
type
TMyObject = Class (Tobject)
protected
procedure DoClick(var msg); message 3;
procedure DoClick2(var msg); message 4;
public
procedure Test;
end;
procedure TMyObject.DoClick(var msg);
begin
writeln ('Called DoClick - msg = ' + inttostr(longint(msg)));
end;
procedure TMyObject.DoClick2(var msg);
begin
writeln ('Called DoClick2 = msg = ' + inttostr(longint(msg)));
end;
procedure TMyObject.Test;
var
msg : integer;
begin
msg := 3;
Dispatch(msg);
msg := 4;
Dispatch(msg);
end;
var
MyObject : TMyObject;
begin
MyObject:=TMyObject.Create;
MyObject.Test;
MyObject.Free;
end.
--
==== Programming my first best destiny! ====
Michael A. Hess Miracle Concepts, Inc.
mhess at miraclec.com http://www.miraclec.com
More information about the Lazarus
mailing list