Fix hashCode calculation
Fixes
@@ -181,10 +181,18 @@ final class Utils {
static int hashFor(float a, float b, float c, float d) {
int result = 17;
+ if (a != 0) {
result = (int) (31 * result * a);
+ }
+ if (b != 0) {
result = (int) (31 * result * b);
+ }
+ if (c != 0) {
result = (int) (31 * result * c);
+ }
+ if (d != 0) {
result = (int) (31 * result * d);
+ }
return result;
}
}
