[fpc-pascal] TThread.Queue vs TThread.Synchronize

Sven Barth pascaldragon at googlemail.com
Tue Feb 24 17:17:59 CET 2015


Am 24.02.2015 14:41 schrieb "Michael Schnell" <mschnell at lumino.de>:
>
> On 02/24/2015 11:32 AM, Mattias Gaertner wrote:
>>
>> About closures see for example:
>> https://en.wikipedia.org/wiki/Closure_%28computer_programming%29
>>
> Hence the "pure" closure paradigm does not need object-orientation.
>
> For my feeling it is prone to introduce some contradiction to
object-orientation and maybe such a paradigm seems not very appropriate in
an object language.
>
> Maybe a definition of a closure/anonymous-like construct with respect to
objects might be invented, that auto-creates an instance of some
object-type that inherits a "Closure" (or "Execute") procedure that
automatically performs a free when returning.

Internally Closures are implemented as a class implementing an interface
that provides an Invoke method.

Also Object Pascal is not a pure object oriented language so I'm definitely
not against non-OOP constructs. Keep also in kind though that languages
like C# also have such constructs.

Regards,
Sven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freepascal.org/pipermail/fpc-pascal/attachments/20150224/4f149f95/attachment.html>


More information about the fpc-pascal mailing list