Michael Van Canneyt schrieb:

On Thu, 31 Jul 2008, Florian Klaempfl wrote:

Before we discuss endless about useless stuff, I'll make a proposal for a
first addition: support of the synchronized keyword. It does no more than
protecting a procedure automatically by a critical section so only one thread
can enter it. But I want to extend it. First, it can be applied also to
classes and object:

tmyclass = class(...) synchronized

This means that all classes synchronize against one critical section.

Can you explain this statement ?

All methods of this class are protected by the same critical section ?

Yes.

So in fact only one method of such a class is executing at the same time ?

Yes. Acutally only one thread can enter the class.
_______________________________________________
fpc-devel maillist  -  fpc-devel@lists.freepascal.org
http://lists.freepascal.org/mailman/listinfo/fpc-devel

Reply via email to