On Mon, 13 Sep 2021 22:11:24 GMT, liach <github.com+7806504+li...@openjdk.org> wrote:
>> src/jdk.jfr/share/classes/jdk/jfr/internal/consumer/RepositoryFiles.java >> line 215: >> >>> 213: pathLookup.remove(remove); >>> 214: } >>> 215: added.sort((p1, p2) -> p1.compareTo(p2)); >> >> 'added.sort(Path::compareTo)' > > Can't we just use natural ordering `null` here? Replaced with `Collections.sort` without comparator argument. I think it's a bit easier to read than with `null`. https://github.com/openjdk/jdk/pull/5229#discussion_r695525255 ------------- PR: https://git.openjdk.java.net/jdk/pull/5230