RFR: 8274190: Use String.equals instead of String.compareTo in jdk.internal.jvmstat [v2]
    Andrey Turbanov 
    github.com+741251+turbanoff at openjdk.java.net
       
    Fri Sep 24 07:05:24 UTC 2021
    
    
  
> In several places, String.compareTo was _compared_ with 0 ( via `== 0` or `!= 0`).
> Instead of this, we can use String.equals calls. `String.equals` is faster and shorter.
Andrey Turbanov has updated the pull request incrementally with one additional commit since the last revision:
  8274190: Use String.equals instead of String.compareTo in jdk.internal.jvmstat
  cleanup redundant parentheses
-------------
Changes:
  - all: https://git.openjdk.java.net/jdk/pull/5638/files
  - new: https://git.openjdk.java.net/jdk/pull/5638/files/f5e58485..167ccfe1
Webrevs:
 - full: https://webrevs.openjdk.java.net/?repo=jdk&pr=5638&range=01
 - incr: https://webrevs.openjdk.java.net/?repo=jdk&pr=5638&range=00-01
  Stats: 3 lines in 2 files changed: 0 ins; 0 del; 3 mod
  Patch: https://git.openjdk.java.net/jdk/pull/5638.diff
  Fetch: git fetch https://git.openjdk.java.net/jdk pull/5638/head:pull/5638
PR: https://git.openjdk.java.net/jdk/pull/5638
    
    
More information about the serviceability-dev
mailing list