On Wed, 16 Apr 2025 14:42:38 GMT, Chen Liang <li...@openjdk.org> wrote:

>> I think Roger's suggestion is for a different JBS issue / PR / CSR.
>
> Yeah, we already added this API to allow implementations to be more 
> consistent under race condition. So for changing char sequences, this 
> method's default implementation can throw IOOBE, but it is already specified 
> so it is well-behaved even under race (as you can argue a read observed the 
> shorter state of the CS that causes the failure)

Omitting it is fine, it was just a reminder that an interface cannot make any 
definitive statements about its implementations and sometime should warn the 
unwary user. (We all expect them to adhere to the contract described in each 
method, but who knows.)
The statement in the implSpec is fine as it only applies to the default 
implementation, but can be mis-read and thought to apply to all 
implementations. YMMV.
And though I see consensus, I don't see any approvals yet, including the CSR.
Its good to see it settle down and make progress.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/21730#discussion_r2047135826

Reply via email to