On Tue, 26 Sep 2023 14:29:05 GMT, Roger Riggs <rri...@openjdk.org> wrote:
>> Aleksei Voitylov has updated the pull request incrementally with one >> additional commit since the last revision: >> >> Update src/java.base/share/classes/java/lang/String.java >> >> Co-authored-by: Raffaello Giulietti <raffaello.giulie...@oracle.com> > > src/java.base/share/classes/java/lang/String.java line 2162: > >> 2160: if (len < 0) { >> 2161: return true; >> 2162: } > > Isn't it also true that the regions trivial match if len == 0? Yes, you are right. The statement "there is some nonnegative integer k less than len " covers the case len == 0, and the rest of the cases are checked before this line. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/15906#discussion_r1337471588