[Lazarus] Doe fpc/lazarus already have System-Threading or is it planned

Sven Barth pascaldragon at googlemail.com
Fri Feb 2 21:37:08 CET 2018


Am 02.02.2018 21:08 schrieb "Zoƫ Peterson via Lazarus" <
lazarus at lists.lazarus-ide.org>:

On 2/2/2018 1:37 PM, R0b0t1 wrote:

> I've been looking for a replacement to
> http://www.omnithreadlibrary.com/ for a long time. If I remember, the
> dealbreaker is the library's codebase making heavy use of anonymous
> functions and procedures.
>

Yeah, OTL requires anonymous methods.  I was hoping to port it to FPC once
the anonymous method support landed, but AFAICT the cross platform port got
pushed into OTL v4 and it looks like that stalled a year ago.


Once FPC supports anonymous functions as well I assume that support will
start to become alive again. ;)



Does System.Threading expose an API that could take either code
> references or anonymous methods? I'm very interested.
>

Yes, System.Threading has both "reference to procedure" and "procedure of
object" overloads in the API, so you could implement most of it in the
current FPC release.  As Sven said, though, no one has started on it, and
anyone who did work on it would have to be careful to not taint it with
code from Delphi's implementation.


The suggested way is to write tests for the Delphi implementation and to
implement the FPC one based on those tests and the Delphi documentation.

Regards,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20180202/5924c06d/attachment-0001.html>


More information about the Lazarus mailing list