Message52533
| Author |
gvanrossum |
| Recipients |
| Date |
2007年05月11日.21:40:26 |
| SpamBayes Score |
| Marked as misclassified |
| Message-id |
| In-reply-to |
| Content |
FWIW, this can run into unchecked infinite recursion easily:
class C:
# There's no @classmethod decorator here as there should have been
def __instancecheck__(self, arg):
return False
isinstance(42, C)
The reason is that on line 372 in classobject.c there's a call to PyObject_IsInstance(self, klass). |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2007年08月23日 15:58:16 | admin | link | issue1708353 messages |
| 2007年08月23日 15:58:16 | admin | create |
|