* fixed runtime

git-svn-id: trunk@1490 -
This commit is contained in:
peter 2005-10-19 06:35:17 +00:00
parent 252d90b691
commit fb6d17fb21

View File

@ -1,16 +1,22 @@
{$mode delphi} {$ifdef fpc}{$mode delphi}{$endif}
type type
tprocedure = procedure; tprocedure = procedure;
pprocedure = ^tprocedure; pprocedure = ^tprocedure;
var var
l : longint; l : longint;
l2 : tprocedure;
function _f1 : plongint; function _f1 : plongint;
begin begin
result:=@l; result:=@l;
end; end;
function _f2 : pprocedure;
begin
result:=@@l2;
end;
var var
f1 : function : plongint; f1 : function : plongint;
f2 : function : pprocedure; f2 : function : pprocedure;
@ -21,6 +27,8 @@ procedure p;
end; end;
begin begin
f1:=_f1;
f2:=_f2;
f1^:=1; f1^:=1;
if l<>1 then if l<>1 then
halt(1); halt(1);