mirror of
https://github.com/django/django.git
synced 2025-10-24 14:16:09 +00:00
Replaced im_func and im_self by __func__ and __self__.
The new names are Python 3 compatible.
This commit is contained in:
@@ -6,8 +6,8 @@ from django.dispatch import saferef
|
||||
WEAKREF_TYPES = (weakref.ReferenceType, saferef.BoundMethodWeakref)
|
||||
|
||||
def _make_id(target):
|
||||
if hasattr(target, 'im_func'):
|
||||
return (id(target.im_self), id(target.im_func))
|
||||
if hasattr(target, '__func__'):
|
||||
return (id(target.__self__), id(target.__func__))
|
||||
return id(target)
|
||||
|
||||
class Signal(object):
|
||||
|
||||
Reference in New Issue
Block a user