|
35 | 35 |
|
36 | 36 | import com.oracle.graal.python.builtins.objects.PNotImplemented;
|
37 | 37 | import com.oracle.graal.python.builtins.objects.str.StringUtils;
|
| 38 | +import com.oracle.graal.python.builtins.objects.type.SpecialMethodSlot; |
38 | 39 | import com.oracle.graal.python.nodes.ErrorMessages;
|
39 | 40 | import com.oracle.graal.python.nodes.PRaiseNode;
|
40 | 41 | import com.oracle.graal.python.nodes.call.special.LookupAndCallBinaryNode;
|
|
46 | 47 | import com.oracle.graal.python.nodes.expression.BinaryComparisonNodeFactory.NeNodeGen;
|
47 | 48 | import com.oracle.graal.python.nodes.object.IsNode;
|
48 | 49 | import com.oracle.graal.python.nodes.truffle.PythonArithmeticTypes;
|
| 50 | +import com.oracle.graal.python.runtime.formatting.InternalFormat.Spec; |
49 | 51 | import com.oracle.truffle.api.CompilerDirectives;
|
50 | 52 | import com.oracle.truffle.api.dsl.Cached;
|
51 | 53 | import com.oracle.truffle.api.dsl.Specialization;
|
@@ -155,7 +157,7 @@ protected final Object doGeneric(VirtualFrame frame, Object left, Object right,
|
155 | 157 | }
|
156 | 158 |
|
157 | 159 | protected static LookupAndCallBinaryNode createCallNode() {
|
158 |
| - return LookupAndCallBinaryNode.create(__LE__, __GE__, true, true); |
| 160 | + return LookupAndCallBinaryNode.create(SpecialMethodSlot.Le, SpecialMethodSlot.Ge, true, true); |
159 | 161 | }
|
160 | 162 |
|
161 | 163 | @Override
|
@@ -227,7 +229,7 @@ protected final Object doGeneric(VirtualFrame frame, Object left, Object right,
|
227 | 229 | }
|
228 | 230 |
|
229 | 231 | protected static LookupAndCallBinaryNode createCallNode() {
|
230 |
| - return LookupAndCallBinaryNode.create(__LT__, __GT__, true, true); |
| 232 | + return LookupAndCallBinaryNode.create(SpecialMethodSlot.Lt, SpecialMethodSlot.Gt, true, true); |
231 | 233 | }
|
232 | 234 |
|
233 | 235 | @Override
|
@@ -299,7 +301,7 @@ protected final Object doGeneric(VirtualFrame frame, Object left, Object right,
|
299 | 301 | }
|
300 | 302 |
|
301 | 303 | protected static LookupAndCallBinaryNode createCallNode() {
|
302 |
| - return LookupAndCallBinaryNode.create(__GE__, __LE__, true, true); |
| 304 | + return LookupAndCallBinaryNode.create(SpecialMethodSlot.Ge, SpecialMethodSlot.Le, true, true); |
303 | 305 | }
|
304 | 306 |
|
305 | 307 | @Override
|
@@ -371,7 +373,7 @@ protected final Object doGeneric(VirtualFrame frame, Object left, Object right,
|
371 | 373 | }
|
372 | 374 |
|
373 | 375 | protected static LookupAndCallBinaryNode createCallNode() {
|
374 |
| - return LookupAndCallBinaryNode.create(__GT__, __LT__, true, true); |
| 376 | + return LookupAndCallBinaryNode.create(SpecialMethodSlot.Gt, SpecialMethodSlot.Lt, true, true); |
375 | 377 | }
|
376 | 378 |
|
377 | 379 | @Override
|
@@ -445,7 +447,7 @@ protected final Object doGeneric(VirtualFrame frame, Object left, Object right,
|
445 | 447 | }
|
446 | 448 |
|
447 | 449 | protected static LookupAndCallBinaryNode createCallNode() {
|
448 |
| - return LookupAndCallBinaryNode.create(__EQ__, __EQ__, true, true); |
| 450 | + return LookupAndCallBinaryNode.create(SpecialMethodSlot.Eq, SpecialMethodSlot.Eq, true, true); |
449 | 451 | }
|
450 | 452 |
|
451 | 453 | public static EqNode create() {
|
@@ -514,7 +516,7 @@ protected final Object doGeneric(VirtualFrame frame, Object left, Object right,
|
514 | 516 | }
|
515 | 517 |
|
516 | 518 | protected static LookupAndCallBinaryNode createCallNode() {
|
517 |
| - return LookupAndCallBinaryNode.create(__NE__, __NE__, true, true); |
| 519 | + return LookupAndCallBinaryNode.create(SpecialMethodSlot.Ne, SpecialMethodSlot.Ne, true, true); |
518 | 520 | }
|
519 | 521 |
|
520 | 522 | public static NeNode create() {
|
|
0 commit comments