PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args == 2 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == METH_O &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}
PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args != 0 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == (METH_FASTCALL|METH_KEYWORDS) &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}
PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args == 1 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == METH_NOARGS &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}
PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args != 0 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == METH_FASTCALL &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}
PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args == 2 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == METH_O &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}
PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args != 0 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == (METH_FASTCALL|METH_KEYWORDS) &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}
PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args == 1 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == METH_NOARGS &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}
PyObject *callable_o = sym_get_const(ctx, callable);
if (callable_o && sym_matches_type(callable, &PyMethodDescr_Type)) {
int total_args = oparg;
- if (!sym_is_null(self_or_null)) {
+ if (sym_is_not_null(self_or_null)) {
total_args++;
}
- PyObject *self = NULL;
- if (!sym_is_null(self_or_null)) {
- self = sym_get_const(ctx, self_or_null);
- } else {
- self = sym_get_const(ctx, args[0]);
+ PyTypeObject *self_type = NULL;
+ if (sym_is_not_null(self_or_null)) {
+ self_type = sym_get_type(self_or_null);
+ }
+ else {
+ self_type = sym_get_type(args[0]);
}
PyTypeObject *d_type = ((PyMethodDescrObject *)callable_o)->d_common.d_type;
if (total_args != 0 &&
((PyMethodDescrObject *)callable_o)->d_method->ml_flags == METH_FASTCALL &&
- self && Py_IS_TYPE(self, d_type)) {
+ self_type == d_type) {
ADD_OP(_NOP, 0, 0);
}
}