mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-12 17:29:37 +02:00
29 lines
343 B
ObjectPascal
29 lines
343 B
ObjectPascal
program test;
|
|
|
|
{$mode objfpc}
|
|
{$inline on}
|
|
|
|
type
|
|
TTest = procedure of object;
|
|
|
|
TMyRecord = record
|
|
Test: TTest;
|
|
end;
|
|
|
|
TMyObject = class
|
|
procedure Test;
|
|
end;
|
|
|
|
function TMyRecordMake(const Test: TTest): TMyRecord; inline;
|
|
begin
|
|
Result.Test := Test;
|
|
end;
|
|
|
|
procedure TMyObject.Test;
|
|
begin
|
|
TMyRecordMake(nil);
|
|
end;
|
|
|
|
begin
|
|
end.
|