Message25346
| Author |
arigo |
| Recipients |
| Date |
2005年05月15日.23:43:47 |
| SpamBayes Score |
| Marked as misclassified |
| Message-id |
| In-reply-to |
| Content |
There is a general way to cause unchecked infinite recursion at the C level, and I have no clue at the moment how it could be reasonably fixed. The idea is to define special __xxx__ methods in such a way that no Python code is actually called before they invoke more special methods (e.g. themselves).
>>> class A: pass
>>> A.__mul__=new.instancemethod(operator.mul,None,A)
>>> A()*2
Segmentation fault |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2007年08月23日 14:31:54 | admin | link | issue1202533 messages |
| 2007年08月23日 14:31:54 | admin | create |
|