Skip to content

Commit 5facbad

Browse files
committed
More minor refactorings
1 parent 7409467 commit 5facbad

File tree

53 files changed

+436
-355
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

53 files changed

+436
-355
lines changed

graalpython/com.oracle.graal.python.processor/src/com/oracle/graal/python/processor/SlotsMapping.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ static String getSlotNodeBaseClass(Slot s) {
117117
static String getUncachedExecuteSignature(SlotKind s) {
118118
return switch (s) {
119119
case nb_bool -> "boolean executeUncached(Object self)";
120-
case tp_richcompare -> "Object executeUncached(Object self, Object obj, com.oracle.graal.python.builtins.objects.type.slots.TpSlotRichCompare.RichCmpOp op)";
120+
case tp_richcompare -> "Object executeUncached(Object self, Object obj, com.oracle.graal.python.lib.RichCmpOp op)";
121121
case tp_descr_get -> "Object executeUncached(Object self, Object obj, Object type)";
122122
case sq_length, mp_length -> "int executeUncached(Object self)";
123123
default -> throw new AssertionError("Should not reach here: should be always complex");

graalpython/com.oracle.graal.python.test/src/com/oracle/graal/python/test/objects/ObjectHashMapTests.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@
5252
import java.util.Random;
5353
import java.util.stream.Collectors;
5454

55+
import com.oracle.graal.python.lib.RichCmpOp;
5556
import org.junit.Assert;
5657
import org.junit.Test;
5758

@@ -67,7 +68,6 @@
6768
import com.oracle.graal.python.builtins.objects.common.ObjectHashMap;
6869
import com.oracle.graal.python.builtins.objects.common.ObjectHashMap.MapCursor;
6970
import com.oracle.graal.python.builtins.objects.common.ObjectHashMap.PopNode;
70-
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotRichCompare;
7171
import com.oracle.graal.python.lib.PyObjectHashNode;
7272
import com.oracle.graal.python.lib.PyObjectRichCompareBool;
7373
import com.oracle.truffle.api.frame.Frame;
@@ -88,7 +88,7 @@ public static final class DictKey implements TruffleObject {
8888

8989
private static final class EqNodeStub extends PyObjectRichCompareBool {
9090
@Override
91-
public boolean execute(Frame frame, Node inliningTarget, Object a, Object b, TpSlotRichCompare.RichCmpOp cmp) {
91+
public boolean execute(Frame frame, Node inliningTarget, Object a, Object b, RichCmpOp cmp) {
9292
// Sanity check: we do not use any other keys in the tests
9393
assert a instanceof Long || a instanceof DictKey;
9494
assert b instanceof Long || b instanceof DictKey;

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

+1-1
Original file line numberDiff line numberDiff line change
@@ -166,7 +166,7 @@
166166
import com.oracle.graal.python.builtins.objects.type.TypeNodes.IsSameTypeNode;
167167
import com.oracle.graal.python.builtins.objects.type.TypeNodes.IsTypeNode;
168168
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotIterNext.CallSlotTpIterNextNode;
169-
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotRichCompare.RichCmpOp;
169+
import com.oracle.graal.python.lib.RichCmpOp;
170170
import com.oracle.graal.python.compiler.Compiler;
171171
import com.oracle.graal.python.compiler.RaisePythonExceptionErrorCallback;
172172
import com.oracle.graal.python.lib.PyCallableCheckNode;

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/cext/PythonCextUnicodeBuiltins.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@
130130
import com.oracle.graal.python.builtins.objects.str.StringBuiltins.ReplaceNode;
131131
import com.oracle.graal.python.builtins.objects.str.StringBuiltins.StartsWithNode;
132132
import com.oracle.graal.python.builtins.objects.str.StringNodes;
133-
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotRichCompare.RichCmpOp;
133+
import com.oracle.graal.python.lib.RichCmpOp;
134134
import com.oracle.graal.python.lib.PyObjectIsTrueNode;
135135
import com.oracle.graal.python.lib.PyObjectLookupAttr;
136136
import com.oracle.graal.python.lib.PySliceNew;

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/functools/KeyWrapperBuiltins.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@
5858
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotRichCompare;
5959
import com.oracle.graal.python.lib.PyObjectIsTrueNode;
6060
import com.oracle.graal.python.lib.PyObjectRichCompare;
61+
import com.oracle.graal.python.lib.RichCmpOp;
6162
import com.oracle.graal.python.nodes.PRaiseNode;
6263
import com.oracle.graal.python.nodes.call.CallNode;
6364
import com.oracle.graal.python.nodes.function.PythonBuiltinBaseNode;
@@ -91,7 +92,7 @@ public void initialize(Python3Core core) {
9192
@GenerateNodeFactory
9293
abstract static class KeyWrapperRichCmpNode extends TpSlotRichCompare.RichCmpBuiltinNode {
9394
@Specialization
94-
boolean doCompare(VirtualFrame frame, PKeyWrapper self, PKeyWrapper other, TpSlotRichCompare.RichCmpOp op,
95+
boolean doCompare(VirtualFrame frame, PKeyWrapper self, PKeyWrapper other, RichCmpOp op,
9596
@Bind("this") Node inliningTarget,
9697
@Cached CallNode callNode,
9798
@Cached PyObjectRichCompare richCompareNode,
@@ -102,7 +103,7 @@ boolean doCompare(VirtualFrame frame, PKeyWrapper self, PKeyWrapper other, TpSlo
102103

103104
@Fallback
104105
@SuppressWarnings("unused")
105-
static boolean fallback(Object self, Object other, TpSlotRichCompare.RichCmpOp op,
106+
static boolean fallback(Object self, Object other, RichCmpOp op,
106107
@Bind("this") Node inliningTarget) {
107108
throw PRaiseNode.raiseStatic(inliningTarget, PythonBuiltinClassType.TypeError, OTHER_ARG_MUST_BE_KEY);
108109
}

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/modules/io/TextIOWrapperBuiltins.java

+2-2
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,6 @@
146146
import com.oracle.graal.python.builtins.objects.tuple.PTuple;
147147
import com.oracle.graal.python.builtins.objects.type.TpSlots;
148148
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotIterNext.TpIterNextBuiltin;
149-
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotRichCompare;
150149
import com.oracle.graal.python.lib.PyErrChainExceptions;
151150
import com.oracle.graal.python.lib.PyLongAsLongNode;
152151
import com.oracle.graal.python.lib.PyNumberAsSizeNode;
@@ -158,6 +157,7 @@
158157
import com.oracle.graal.python.lib.PyObjectReprAsTruffleStringNode;
159158
import com.oracle.graal.python.lib.PyObjectRichCompareBool;
160159
import com.oracle.graal.python.lib.PyObjectSizeNode;
160+
import com.oracle.graal.python.lib.RichCmpOp;
161161
import com.oracle.graal.python.nodes.PRaiseNode;
162162
import com.oracle.graal.python.nodes.function.PythonBuiltinBaseNode;
163163
import com.oracle.graal.python.nodes.function.PythonBuiltinNode;
@@ -695,7 +695,7 @@ static Object seek(VirtualFrame frame, PTextIO self, Object c, int whence,
695695
switch (whence) {
696696
case SEEK_CUR:
697697
/* seek relative to current position */
698-
if (!eqNode.execute(frame, inliningTarget, cookieObj, 0, TpSlotRichCompare.RichCmpOp.Py_EQ)) {
698+
if (!eqNode.execute(frame, inliningTarget, cookieObj, 0, RichCmpOp.Py_EQ)) {
699699
throw raiseNode.raise(inliningTarget, IOUnsupportedOperation, CAN_T_DO_NONZERO_CUR_RELATIVE_SEEKS);
700700
}
701701

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/array/ArrayBuiltins.java

+14-13
Original file line numberDiff line numberDiff line change
@@ -97,6 +97,7 @@
9797
import com.oracle.graal.python.lib.PyObjectRichCompare;
9898
import com.oracle.graal.python.lib.PyObjectRichCompareBool;
9999
import com.oracle.graal.python.lib.PyObjectSizeNode;
100+
import com.oracle.graal.python.lib.RichCmpOp;
100101
import com.oracle.graal.python.nodes.ErrorMessages;
101102
import com.oracle.graal.python.nodes.PGuards;
102103
import com.oracle.graal.python.nodes.PRaiseNode;
@@ -280,7 +281,7 @@ static Object concat(PArray self, int value,
280281
abstract static class ArrayRichCmpNode extends TpSlotRichCompare.RichCmpBuiltinNode {
281282

282283
@Specialization(guards = "!isFloatingPoint(left.getFormat()) || (left.getFormat() != right.getFormat())")
283-
static Object cmpItems(VirtualFrame frame, PArray left, PArray right, TpSlotRichCompare.RichCmpOp op,
284+
static Object cmpItems(VirtualFrame frame, PArray left, PArray right, RichCmpOp op,
284285
@Bind Node inliningTarget,
285286
@Exclusive @Cached InlinedBranchProfile fullCmpProfile,
286287
@Exclusive @Cached PyObjectRichCompareBool richCmpEqNode,
@@ -290,18 +291,18 @@ static Object cmpItems(VirtualFrame frame, PArray left, PArray right, TpSlotRich
290291
@Exclusive @Cached InlinedLoopConditionProfile loopProfile) {
291292
if (left.getLength() != right.getLength() && op.isEqOrNe()) {
292293
// the same fast-path as CPython
293-
return op == TpSlotRichCompare.RichCmpOp.Py_NE;
294+
return op == RichCmpOp.Py_NE;
294295
}
295296
fullCmpProfile.enter(inliningTarget);
296297
int commonLength = Math.min(left.getLength(), right.getLength());
297298
loopProfile.profileCounted(inliningTarget, commonLength); // ignoring the early exit
298299
for (int i = 0; loopProfile.inject(inliningTarget, i < commonLength); i++) {
299300
Object leftValue = getLeft.execute(inliningTarget, left, i);
300301
Object rightValue = getRight.execute(inliningTarget, right, i);
301-
if (!richCmpEqNode.execute(frame, inliningTarget, leftValue, rightValue, TpSlotRichCompare.RichCmpOp.Py_EQ)) {
302-
if (op == TpSlotRichCompare.RichCmpOp.Py_EQ) {
302+
if (!richCmpEqNode.execute(frame, inliningTarget, leftValue, rightValue, RichCmpOp.Py_EQ)) {
303+
if (op == RichCmpOp.Py_EQ) {
303304
return false;
304-
} else if (op == TpSlotRichCompare.RichCmpOp.Py_NE) {
305+
} else if (op == RichCmpOp.Py_NE) {
305306
return true;
306307
}
307308
return richCmpOpNode.execute(frame, inliningTarget, leftValue, rightValue, op);
@@ -322,15 +323,15 @@ static Object cmpItems(VirtualFrame frame, PArray left, PArray right, TpSlotRich
322323
// be preserved, so here we know for sure that if we see two NaNs, PyObjectRichCompareBool
323324
// would return false on CPython, and so we do the same. This is tested in CPython tests.
324325
@Specialization(guards = {"isFloatingPoint(left.getFormat())", "left.getFormat() == right.getFormat()"})
325-
static boolean cmpDoubles(VirtualFrame frame, PArray left, PArray right, TpSlotRichCompare.RichCmpOp op,
326+
static boolean cmpDoubles(VirtualFrame frame, PArray left, PArray right, RichCmpOp op,
326327
@Bind("$node") Node inliningTarget,
327328
@Exclusive @Cached InlinedBranchProfile fullCmpProfile,
328329
@Exclusive @Cached ArrayNodes.GetValueNode getLeft,
329330
@Exclusive @Cached ArrayNodes.GetValueNode getRight,
330331
@Exclusive @Cached InlinedLoopConditionProfile loopProfile) {
331332
if (left.getLength() != right.getLength() && op.isEqOrNe()) {
332333
// the same fast-path as CPython
333-
return op == TpSlotRichCompare.RichCmpOp.Py_NE;
334+
return op == RichCmpOp.Py_NE;
334335
}
335336
fullCmpProfile.enter(inliningTarget);
336337
int commonLength = Math.min(left.getLength(), right.getLength());
@@ -350,13 +351,13 @@ static boolean cmpDoubles(VirtualFrame frame, PArray left, PArray right, TpSlotR
350351

351352
@Specialization(guards = "!isArray(right)")
352353
@SuppressWarnings("unused")
353-
static Object cmp(PArray left, Object right, TpSlotRichCompare.RichCmpOp op) {
354+
static Object cmp(PArray left, Object right, RichCmpOp op) {
354355
return PNotImplemented.NOT_IMPLEMENTED;
355356
}
356357

357358
@Specialization(guards = "!isArray(left)")
358359
@SuppressWarnings("unused")
359-
static Object error(Object left, Object right, TpSlotRichCompare.RichCmpOp op,
360+
static Object error(Object left, Object right, RichCmpOp op,
360361
@Bind("this") Node inliningTarget) {
361362
throw PRaiseNode.raiseStatic(inliningTarget, PythonErrorType.TypeError, ErrorMessages.DESCRIPTOR_S_REQUIRES_S_OBJ_RECEIVED_P, op.getPythonName(), J_ARRAY + "." + J_ARRAY, left);
362363
}
@@ -371,7 +372,7 @@ static boolean contains(VirtualFrame frame, PArray self, Object value,
371372
@Cached PyObjectRichCompareBool eqNode,
372373
@Cached ArrayNodes.GetValueNode getValueNode) {
373374
for (int i = 0; i < self.getLength(); i++) {
374-
if (eqNode.execute(frame, inliningTarget, getValueNode.execute(inliningTarget, self, i), value, TpSlotRichCompare.RichCmpOp.Py_EQ)) {
375+
if (eqNode.execute(frame, inliningTarget, getValueNode.execute(inliningTarget, self, i), value, RichCmpOp.Py_EQ)) {
375376
return true;
376377
}
377378
}
@@ -927,7 +928,7 @@ static Object remove(VirtualFrame frame, PArray self, Object value,
927928
@Cached PRaiseNode raiseNode) {
928929
for (int i = 0; i < self.getLength(); i++) {
929930
Object item = getValueNode.execute(inliningTarget, self, i);
930-
if (eqNode.execute(frame, inliningTarget, item, value, TpSlotRichCompare.RichCmpOp.Py_EQ)) {
931+
if (eqNode.execute(frame, inliningTarget, item, value, RichCmpOp.Py_EQ)) {
931932
self.checkCanResize(inliningTarget, raiseNode);
932933
deleteSliceNode.execute(inliningTarget, self, i, 1);
933934
return PNone.NONE;
@@ -1274,7 +1275,7 @@ static int index(VirtualFrame frame, PArray self, Object value, int start, int s
12741275
stop += length;
12751276
}
12761277
for (int i = start; i < stop && i < length; i++) {
1277-
if (eqNode.execute(frame, inliningTarget, getValueNode.execute(inliningTarget, self, i), value, TpSlotRichCompare.RichCmpOp.Py_EQ)) {
1278+
if (eqNode.execute(frame, inliningTarget, getValueNode.execute(inliningTarget, self, i), value, RichCmpOp.Py_EQ)) {
12781279
return i;
12791280
}
12801281
}
@@ -1297,7 +1298,7 @@ static int count(VirtualFrame frame, PArray self, Object value,
12971298
@Cached ArrayNodes.GetValueNode getValueNode) {
12981299
int count = 0;
12991300
for (int i = 0; i < self.getLength(); i++) {
1300-
if (eqNode.execute(frame, inliningTarget, getValueNode.execute(inliningTarget, self, i), value, TpSlotRichCompare.RichCmpOp.Py_EQ)) {
1301+
if (eqNode.execute(frame, inliningTarget, getValueNode.execute(inliningTarget, self, i), value, RichCmpOp.Py_EQ)) {
13011302
count++;
13021303
}
13031304
}

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/bytes/ByteArrayBuiltins.java

+6-5
Original file line numberDiff line numberDiff line change
@@ -82,6 +82,7 @@
8282
import com.oracle.graal.python.lib.PyNumberAsSizeNode;
8383
import com.oracle.graal.python.lib.PyObjectGetStateNode;
8484
import com.oracle.graal.python.lib.PySliceNew;
85+
import com.oracle.graal.python.lib.RichCmpOp;
8586
import com.oracle.graal.python.nodes.ErrorMessages;
8687
import com.oracle.graal.python.nodes.PRaiseNode;
8788
import com.oracle.graal.python.nodes.SpecialAttributeNames;
@@ -832,9 +833,9 @@ static Object reduce(VirtualFrame frame, PByteArray self,
832833

833834
@Slot(value = SlotKind.tp_richcompare, isComplex = true)
834835
@GenerateNodeFactory
835-
abstract static class ComparisonHelperNode extends TpSlotRichCompare.RichCmpBuiltinNode {
836+
abstract static class RichCmpNode extends TpSlotRichCompare.RichCmpBuiltinNode {
836837
@Specialization
837-
static boolean cmp(PByteArray self, PBytesLike other, TpSlotRichCompare.RichCmpOp op,
838+
static boolean cmp(PByteArray self, PBytesLike other, RichCmpOp op,
838839
@Bind("$node") Node inliningTarget,
839840
@Exclusive @Cached GetInternalByteArrayNode getArray) {
840841
SequenceStorage selfStorage = self.getSequenceStorage();
@@ -844,7 +845,7 @@ static boolean cmp(PByteArray self, PBytesLike other, TpSlotRichCompare.RichCmpO
844845

845846
@Specialization(guards = {"check.execute(inliningTarget, self)", "acquireLib.hasBuffer(other)"}, limit = "3")
846847
@InliningCutoff
847-
static Object cmp(VirtualFrame frame, Object self, Object other, TpSlotRichCompare.RichCmpOp op,
848+
static Object cmp(VirtualFrame frame, Object self, Object other, RichCmpOp op,
848849
@Bind("$node") Node inliningTarget,
849850
@Cached("createFor(this)") IndirectCallData indirectCallData,
850851
@SuppressWarnings("unused") @Exclusive @Cached PyByteArrayCheckNode check,
@@ -864,7 +865,7 @@ static Object cmp(VirtualFrame frame, Object self, Object other, TpSlotRichCompa
864865

865866
@Specialization(guards = {"check.execute(inliningTarget, self)", "!acquireLib.hasBuffer(other)"})
866867
@SuppressWarnings("unused")
867-
static Object cmp(VirtualFrame frame, Object self, Object other, TpSlotRichCompare.RichCmpOp op,
868+
static Object cmp(VirtualFrame frame, Object self, Object other, RichCmpOp op,
868869
@Bind("$node") Node inliningTarget,
869870
@Shared @Cached PyByteArrayCheckNode check,
870871
@CachedLibrary(limit = "3") PythonBufferAcquireLibrary acquireLib) {
@@ -874,7 +875,7 @@ static Object cmp(VirtualFrame frame, Object self, Object other, TpSlotRichCompa
874875
@Specialization(guards = "!check.execute(inliningTarget, self)")
875876
@InliningCutoff
876877
@SuppressWarnings("unused")
877-
static Object error(VirtualFrame frame, Object self, Object other, TpSlotRichCompare.RichCmpOp op,
878+
static Object error(VirtualFrame frame, Object self, Object other, RichCmpOp op,
878879
@Bind("$node") Node inliningTarget,
879880
@Shared @Cached PyByteArrayCheckNode check) {
880881
throw PRaiseNode.raiseStatic(inliningTarget, TypeError, ErrorMessages.DESCRIPTOR_S_REQUIRES_S_OBJ_RECEIVED_P, op.getPythonName(), J_BYTEARRAY, self);

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/bytes/BytesBuiltins.java

+4-3
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
import com.oracle.graal.python.lib.PyBytesCheckExactNode;
5858
import com.oracle.graal.python.lib.PyBytesCheckNode;
5959
import com.oracle.graal.python.lib.PyIndexCheckNode;
60+
import com.oracle.graal.python.lib.RichCmpOp;
6061
import com.oracle.graal.python.nodes.ErrorMessages;
6162
import com.oracle.graal.python.nodes.PRaiseNode;
6263
import com.oracle.graal.python.nodes.call.CallNode;
@@ -263,9 +264,9 @@ protected ArgumentClinicProvider getArgumentClinic() {
263264
@GenerateUncached
264265
// N.B. bytes only allow comparing to bytes, bytearray has its own implementation that uses
265266
// buffer API
266-
abstract static class ComparisonHelperNode extends TpSlotRichCompare.RichCmpBuiltinNode {
267+
abstract static class RichCmpNode extends TpSlotRichCompare.RichCmpBuiltinNode {
267268
@Specialization
268-
static boolean cmp(PBytes self, PBytes other, TpSlotRichCompare.RichCmpOp op,
269+
static boolean cmp(PBytes self, PBytes other, RichCmpOp op,
269270
@Bind("$node") Node inliningTarget,
270271
@Exclusive @Cached SequenceStorageNodes.GetInternalByteArrayNode getArray) {
271272
SequenceStorage selfStorage = self.getSequenceStorage();
@@ -274,7 +275,7 @@ static boolean cmp(PBytes self, PBytes other, TpSlotRichCompare.RichCmpOp op,
274275
}
275276

276277
@Fallback
277-
static Object cmp(Object self, Object other, TpSlotRichCompare.RichCmpOp op,
278+
static Object cmp(Object self, Object other, RichCmpOp op,
278279
@Bind("$node") Node inliningTarget,
279280
@SuppressWarnings("unused") @Cached PyBytesCheckNode check,
280281
@Cached BytesNodes.GetBytesStorage getBytesStorage,

graalpython/com.oracle.graal.python/src/com/oracle/graal/python/builtins/objects/bytes/BytesNodes.java

+3-3
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,6 @@
7676
import com.oracle.graal.python.builtins.objects.iterator.IteratorNodes;
7777
import com.oracle.graal.python.builtins.objects.str.PString;
7878
import com.oracle.graal.python.builtins.objects.str.StringNodes;
79-
import com.oracle.graal.python.builtins.objects.type.slots.TpSlotRichCompare;
8079
import com.oracle.graal.python.lib.PyByteArrayCheckNode;
8180
import com.oracle.graal.python.lib.PyBytesCheckNode;
8281
import com.oracle.graal.python.lib.PyIndexCheckNode;
@@ -85,6 +84,7 @@
8584
import com.oracle.graal.python.lib.PyOSFSPathNode;
8685
import com.oracle.graal.python.lib.PyObjectGetIter;
8786
import com.oracle.graal.python.lib.PyUnicodeCheckNode;
87+
import com.oracle.graal.python.lib.RichCmpOp;
8888
import com.oracle.graal.python.nodes.ErrorMessages;
8989
import com.oracle.graal.python.nodes.PGuards;
9090
import com.oracle.graal.python.nodes.PNodeWithContext;
@@ -984,10 +984,10 @@ public static int adjustEndIndex(int endIn, int len) {
984984
return endIn;
985985
}
986986

987-
static boolean compareByteArrays(TpSlotRichCompare.RichCmpOp op, byte[] selfArray, int selfLength, byte[] otherArray, int otherLength) {
987+
static boolean compareByteArrays(RichCmpOp op, byte[] selfArray, int selfLength, byte[] otherArray, int otherLength) {
988988
int compareResult = 0;
989989
if (op.isEqOrNe() && selfLength != otherLength) {
990-
return op == TpSlotRichCompare.RichCmpOp.Py_NE;
990+
return op == RichCmpOp.Py_NE;
991991
}
992992
for (int i = 0; i < Math.min(selfLength, otherLength); i++) {
993993
compareResult = Byte.compareUnsigned(selfArray[i], otherArray[i]);

0 commit comments

Comments
 (0)