On Thu, 4 Aug 2022 10:00:58 GMT, Alan Bateman <al...@openjdk.org> wrote:
>> Alex and I discussed this and we felt that it was important to call out all >> three "kinds" of threads explicitly. Earlier versions of the text implied >> that no non-daemon threads were running at the time the VM terminated, which >> might not be true. Earlier text also implied that shutdown hooks had >> terminated before the VM terminated, but this isn't necessarily true if >> somebody calls halt(). Yes, a shutdown hook has a daemon/non-daemon bit, but >> effectively it's ignored, and a shutdown hook is treated so specially that >> it's effectively a different kind of thread. > > I understand but as currently worded the reader may wonder what > Thread::isDaemon might return when it invoked on Thread that is a shutdown > hook. I think the best I can suggest is to replace "daemon, non-daemon, and > shutdown hooks" with "shutdown hooks and other daemon and non-daemon threads". OK I used this wording. ------------- PR: https://git.openjdk.org/jdk/pull/9437