Re: More accurate wording for java.util.concurrent.TimeUnit.sleep
Martin Buchholz via Concurrency-interest <[email protected]>
| Newsgroups | gmane.comp.java.jsr.166-concurrency |
|---|---|
| Message-ID | <CA+kOe08C-UrSE9rKH66gH=9obQwiBDcZzKna=FOBfK+YJ_zNCw@mail.gmail.com> |
I've been a steady advocate of "at least" semantics for methods that specify a duration, including sleep. https://bugs.openjdk.java.net/browse/JDK-6313903 <https://bugs.openjdk.java.net/browse/JDK-6313903?filter=25118> Pavel, if you need to do something surely at 9am, set the alarm for 8am, not 9am! I agree that if Thread.sleep(0) is not really a no-op then TimeUnit.sleep(0) should do the same thing. Doug? _______________________________________________ Concurrency-interest mailing list [email protected] http://cs.oswego.edu/mailman/listinfo/concurrency-interest