[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openjdk-serviceability-dev
Subject:    Re: RFR: 8283800: Simplify String.indexOf/lastIndexOf calls
From:       Leonid Mesnik <lmesnik () openjdk ! java ! net>
Date:       2022-03-28 21:49:55
Message-ID: cPaYDLzdtnYfU97vg_T1VjQ3YU_y7and2eqt5YDqMDg=.7bea1eb2-36e6-4712-b691-086a8f028b7c () github ! com
[Download RAW message or body]

On Sun, 20 Mar 2022 12:45:34 GMT, Andrey Turbanov <aturbanov@openjdk.org> wrote:

> In a few places String.indexOf/lastIndexOf methods are called with default \
> parameter for index: `0` for `indexOf`, length() for `lastIndexOf`. I propose to \
> cleanup such calls. It makes code a bit easier to read. In case of `indexOf` it \
> even could be faster, as there is separate intrinsic for `indexOf` call without \
> index argument.

Marked as reviewed by lmesnik (Reviewer).

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

PR: https://git.openjdk.java.net/jdk/pull/7877


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic