[fpc-pascal] Re: Delphi's anonymous functions in Free Pascal

Bernd prof7bit at googlemail.com
Sun Nov 6 14:41:39 CET 2011


2011/11/6 Florian Klämpfl <florian at freepascal.org>:
> It would be probably more clear to write and this more pascalish:
>
> Procedure SomeOuter;
>
> Var
>  d,e,f : SomeType;
>
>  Lambda Procedure
> SomeInner(targetobject:ttargetobject;a:integer;b:someobject;c:string)
>  begin
>     targetobject.destinationprocedure(a,b,c);
>  end;
>
> begin
>  Targethread.queue(@SomeInner(aobject,d,e,f));
> end;

Why would this function have an argument list? How would the target
thread call it?



More information about the fpc-pascal mailing list