Skip to content

Commit

Permalink
Fix PathFragment to not use Java8-only static hashCode methods.
Browse files Browse the repository at this point in the history
Fixes #2247.

--
PiperOrigin-RevId: 142143520
MOS_MIGRATED_REVID=142143520
  • Loading branch information
katre committed Dec 15, 2016
1 parent a397340 commit 4975760
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -737,12 +737,12 @@ public int hashCode() {
// once.
int h = hashCode;
if (h == 0) {
h = Boolean.hashCode(isAbsolute);
h = Boolean.valueOf(isAbsolute).hashCode();
for (String segment : segments) {
h = h * 31 + segment.hashCode();
}
if (!isEmpty()) {
h = h * 31 + Character.hashCode(driveLetter);
h = h * 31 + Character.valueOf(driveLetter).hashCode();
}
hashCode = h;
}
Expand Down

0 comments on commit 4975760

Please sign in to comment.