Skip to content

Commit 6c57d8b

Browse files
committed
fix shift error for complex identity
1 parent 1115524 commit 6c57d8b

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/BuiltinFunctions.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1043,8 +1043,8 @@ long doPFloat(PFloat value,
10431043
long doComplex(PComplex value,
10441044
@Shared("isBuiltin") @Cached IsBuiltinClassProfile isBuiltin) {
10451045
if (isBuiltin.profileIsAnyBuiltinObject(value)) {
1046-
int imag = Double.hashCode(value.getImag());
1047-
int real = Double.hashCode(value.getReal());
1046+
long imag = Double.hashCode(value.getImag());
1047+
long real = Double.hashCode(value.getReal());
10481048
return (((real << 32) | imag) << IDTAG_SHIFT) | IDTAG_COMPLEX;
10491049
} else {
10501050
return doGeneric(value);

0 commit comments

Comments
 (0)