> Do you still propose that the implementation have the freedom to
> treat:
>
> o.notify();
> t.interrupt();
>
> as
>
> t.interrupt();
> o.notify();
Two answers:
1. If a thread is notified before it is interrupted, wait returns normally,
and if it is interrupted first, wait throws IE and is not notified.
2. There are no guarantees about synchronous effects of
Thread.interrupt (and possibly, as Sylvia mentioned yesterday,
Object.notify), so on the face of it the effects of the above
statements could be reordered. Can you see any point in explicitly
prohibiting this?
-Doug
-------------------------------
JavaMemoryModel mailing list - http://www.cs.umd.edu/~pugh/java/memoryModel
This archive was generated by hypermail 2b29 : Thu Oct 13 2005 - 07:00:55 EDT