Home
last modified time | relevance | path

Searched refs:im_self (Results 1 – 20 of 20) sorted by relevance

/external/python/cpython2/Include/
Dclassobject.h34 PyObject *im_self; /* The instance it is bound to, or NULL */ member
72 (((PyMethodObject *)meth) -> im_self)
/external/python/cpython2/Objects/
Dclassobject.c155 return ((PyMethodObject *)im)->im_self; in PyMethod_Self()
2258 free_list = (PyMethodObject *)(im->im_self); in PyMethod_New()
2271 im->im_self = self; in PyMethod_New()
2291 {"im_self", T_OBJECT, OFF(im_self), READONLY|RESTRICTED,
2293 {"__self__", T_OBJECT, OFF(im_self), READONLY|RESTRICTED,
2388 Py_XDECREF(im->im_self); in instancemethod_dealloc()
2391 im->im_self = (PyObject *)free_list; in instancemethod_dealloc()
2408 if (a->im_self == b->im_self) in instancemethod_compare()
2410 if (a->im_self == NULL || b->im_self == NULL) in instancemethod_compare()
2411 return (a->im_self < b->im_self) ? -1 : 1; in instancemethod_compare()
[all …]
/external/python/cpython2/Lib/test/
Dtest_pyclbr.py77 if obj.im_self is not None:
79 obj.im_self is not oclass):
Dtest_funcattrs.py182 self.assertEqual(self.f.a.im_self, None)
183 self.assertEqual(self.fi.a.im_self, self.fi)
Dtest_descr.py1398 self.assertEqual(C.goo.im_self, C)
1399 self.assertEqual(D.goo.im_self, D)
1400 self.assertEqual(super(D,D).goo.im_self, D)
1401 self.assertEqual(super(D,d).goo.im_self, D)
4476 self.assertIs(l.__add__.im_self, l)
Dtest_copy.py754 self.assertTrue(g.b.im_self is g)
/external/python/cpython2/Lib/multiprocessing/
Dforking.py71 if m.im_self is None:
74 return getattr, (m.im_self, m.im_func.func_name)
/external/python/cpython2/Lib/idlelib/
DCallTips.py170 if ob.im_self is not None:
/external/python/cpython2/Lib/
Dinspect.py929 if ismethod(func) and func.im_self is not None:
931 positional = (func.im_self,) + positional
Dcopy.py264 return type(x)(x.im_func, deepcopy(x.im_self, memo), x.im_class)
Dpydoc.py916 if object.im_self is not None:
918 object.im_self.__class__, mod)
1306 if object.im_self is not None:
1308 object.im_self.__class__, mod)
/external/python/cpython2/Doc/reference/
Ddatamodel.rst571 Special read-only attributes: :attr:`im_self` is the class instance object,
573 :attr:`im_self` for bound methods or the class that asked for the method for
580 :attr:`im_self` used to refer to the class that defined the method.
584 :attr:`__func__`, and :attr:`im_self` as :attr:`__self__`.
591 single: im_self (method attribute)
607 single: im_self (method attribute)
610 function object from a class, its :attr:`im_self` attribute is ``None``
613 instances, its :attr:`im_self` attribute is the instance, and the method
628 single: im_self (method attribute)
631 from a class or instance, its :attr:`im_self` attribute is the class itself, and
[all …]
/external/python/cpython2/Doc/howto/
Ddescriptor.rst310 with two different representations depending on whether the :attr:`im_self`
313 Likewise, the effects of calling a method object depend on the :attr:`im_self`
/external/python/cpython2/Doc/library/
Dinspect.rst64 | | im_self or | instance to which this | |
Dstdtypes.rst2976 methods: ``m.im_self`` is the object on which the method operates, and
2978 arg-2, ..., arg-n)`` is completely equivalent to calling ``m.im_func(m.im_self,
2983 is unbound, its ``im_self`` attribute will be ``None`` and if called, an
/external/python/cpython2/Doc/tutorial/
Dclasses.rst696 Instance method objects have attributes, too: ``m.im_self`` is the instance
/external/python/cpython2/Misc/
Dcheatsheet1267 im_self (instance/None, R/O): target instance object (None if unbound)
DNEWS10238 The two changes are: im_self -> __self__ and im_func -> __func__
DHISTORY1306 with im_class == im_self == NULL, which caused a crash when called.
/external/python/cpython2/Doc/whatsnew/
D2.6.rst1676 comprising the method; the new synonym for :attr:`im_self` is