On Mon, 26 May 2025 16:46:49 GMT, Alan Bateman <al...@openjdk.org> wrote:

>> Aleksey Shipilev has updated the pull request incrementally with one 
>> additional commit since the last revision:
>> 
>>   Move to the end
>
> src/java.base/share/classes/java/util/concurrent/StructuredTaskScopeImpl.java 
> line 70:
> 
>> 68:         this.joiner = joiner;
>> 69:         this.threadFactory = threadFactory;
>> 70:         this.flock = ThreadFlock.open((name != null) ? name : 
>> Objects.toIdentityString(this));
> 
> Unnecessary but okay. Do you mind moving it to the end of constructor as the 
> fields are initialized in order declaration order in this constructor.

Yeah, explicit use of `ST_NEW` avoids future accidents, e.g. if we ever 
introduce a new state that would have to shuffle states around. Moved to the 
end of constructor now.

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/25452#discussion_r2107669807

Reply via email to