https://issues.dlang.org/show_bug.cgi?id=22555
--- Comment #5 from Stanislav Blinov <[email protected]> --- Actually, no, I'm not blind :) task { synchronized (a) // lock, counter = 1 { a.wait(5) { // `this` is a synchronized (this) // already locked, counter = 2 { // So at this point, you've recursed twice // hence main thread blocks in set() condition.wait; // counter = 1, not unlocked // counter = 2 } } } } --- synchronized(a) in task should be removed --
