#define SPEC_FAIL_BINARY_OP_SUBSCR_DEQUE 42
#define SPEC_FAIL_BINARY_OP_SUBSCR_ENUMDICT 43
#define SPEC_FAIL_BINARY_OP_SUBSCR_STACKSUMMARY 44
+#define SPEC_FAIL_BINARY_OP_SUBSCR_DEFAULTDICT 45
+#define SPEC_FAIL_BINARY_OP_SUBSCR_COUNTER 46
+#define SPEC_FAIL_BINARY_OP_SUBSCR_ORDEREDDICT 47
+#define SPEC_FAIL_BINARY_OP_SUBSCR_BYTES 48
+#define SPEC_FAIL_BINARY_OP_SUBSCR_STRUCTTIME 49
+#define SPEC_FAIL_BINARY_OP_SUBSCR_RANGE 50
/* Calls */
return SPEC_FAIL_BINARY_OP_SUBSCR_MAPPINGPROXY;
}
+ if (PyObject_TypeCheck(lhs, &PyBytes_Type)) {
+ return SPEC_FAIL_BINARY_OP_SUBSCR_BYTES;
+ }
+
+ if (PyObject_TypeCheck(lhs, &PyRange_Type)) {
+ return SPEC_FAIL_BINARY_OP_SUBSCR_RANGE;
+ }
+
if (strcmp(container_type->tp_name, "array.array") == 0) {
return SPEC_FAIL_BINARY_OP_SUBSCR_ARRAY;
}
return SPEC_FAIL_BINARY_OP_SUBSCR_STACKSUMMARY;
}
+ if (strcmp(container_type->tp_name, "collections.defaultdict") == 0) {
+ return SPEC_FAIL_BINARY_OP_SUBSCR_DEFAULTDICT;
+ }
+
+ if (strcmp(container_type->tp_name, "Counter") == 0) {
+ return SPEC_FAIL_BINARY_OP_SUBSCR_COUNTER;
+ }
+
+ if (strcmp(container_type->tp_name, "collections.OrderedDict") == 0) {
+ return SPEC_FAIL_BINARY_OP_SUBSCR_ORDEREDDICT;
+ }
+
+ if (strcmp(container_type->tp_name, "time.struct_time") == 0) {
+ return SPEC_FAIL_BINARY_OP_SUBSCR_STRUCTTIME;
+ }
+
if (PySlice_Check(rhs)) {
return SPEC_FAIL_BINARY_OP_SUBSCR_OTHER_SLICE;
}