Walter is right about transitive readonly - here's the alternative
Steven Schveighoffer
schveiguy at yahoo.com
Thu Sep 13 09:38:51 PDT 2007
"Steven Schveighoffer" wrote
> This won't help in the case where two threads deadlock, but there may be
> ways to put debug code in to check those also:
>
> if(object a is locked by thread x && thread x is waiting for object b && I
> have object b locked)
> throw new DeadlockException();
Oops, that doesn't work in the case of more than 2 threads and more than 2
objects. Nevermind... magic bullet is a myth :) but the first one
definitely will work.
-Steve
More information about the Digitalmars-d
mailing list