mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-13 08:59:27 +02:00
24 lines
284 B
ObjectPascal
24 lines
284 B
ObjectPascal
{ %FAIL }
|
|
|
|
program tfuncref27;
|
|
|
|
{$mode objfpc}{$H+}
|
|
{$modeswitch anonymousfunctions}
|
|
{$modeswitch functionreferences}
|
|
|
|
type
|
|
TTestFunc = reference to procedure;
|
|
|
|
function DoTest: TTestFunc;
|
|
|
|
function TestSub: TTestFunc;
|
|
begin
|
|
end;
|
|
|
|
begin
|
|
Result := @TestSub;
|
|
end;
|
|
|
|
begin
|
|
end.
|