File tree Expand file tree Collapse file tree
caffeine/src/main/java/com/github/benmanes/caffeine/cache Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -167,14 +167,19 @@ public void increment(E e) {
167167
168168 /** Applies a supplemental hash functions to defends against poor quality hash. */
169169 int spread (int x ) {
170- x = ((x >>> 17 ) ^ x ) * 0xed5ad4bb ;
171- x = ((x >>> 11 ) ^ x ) * 0xac4c1b51 ;
172- return (x >>> 15 ) ^ x ;
170+ x ^= x >>> 17 ;
171+ x *= 0xed5ad4bb ;
172+ x ^= x >>> 11 ;
173+ x *= 0xac4c1b51 ;
174+ x ^= x >>> 15 ;
175+ return x ;
173176 }
174177
175178 /** Applies another round of hashing for additional randomization. */
176179 int rehash (int x ) {
177- return 0x31848bab * (x >>> 14 ) ^ x ;
180+ x *= 0x31848bab ;
181+ x ^= x >>> 14 ;
182+ return x ;
178183 }
179184
180185 /**
Original file line number Diff line number Diff line change 8787 ]
8888 pluginVersions = [
8989 bnd : ' 6.3.1' ,
90- checkstyle : ' 10.3.3 ' ,
90+ checkstyle : ' 10.3.4 ' ,
9191 coveralls : ' 2.12.0' ,
9292 dependencyCheck : ' 7.2.1' ,
9393 errorprone : ' 2.0.2' ,
You can’t perform that action at this time.
0 commit comments