Le 31/05/2012 16:01, Regan Heath a écrit :
True, it's basically the same as a synchronized block in that respect.
What we actually want is a way to limit the calls made by the delegate
to methods of the object itself. If it could not call a synchronized
method on a 2nd object, you could not possibly deadlock. Except, that is
to say, unless you held a separate lock beforehand - but, the important
point here is that you would have to take both locks explicitly, rather
than by an implicit synchronized method call, making the bug far more
obvious to code inspection.

R


I'm not sure I follow you here. Can you elaborate on that ?

Reply via email to