This issue tracker has been migrated to GitHub ,
and is currently read-only.
For more information,
see the GitHub FAQs in the Python's Developer Guide.
Created on 2007年12月04日 05:43 by alexandre.vassalotti, last changed 2022年04月11日 14:56 by admin. This issue is now closed.
| Messages (4) | |||
|---|---|---|---|
| msg58176 - (view) | Author: Alexandre Vassalotti (alexandre.vassalotti) * (Python committer) | Date: 2007年12月04日 05:43 | |
If an iterator with a __length_hint__ method that returns a negative integer is passed to list(), a SystemError is raised. >>> class A: ... def __iter__(self): ... return self ... def __length_hint__(self): ... return -1 ... >>> list(A()) Traceback (most recent call last): File "<stdin>", line 1, in <module> SystemError: NULL result without error in PyObject_Call |
|||
| msg58178 - (view) | Author: Alexandre Vassalotti (alexandre.vassalotti) * (Python committer) | Date: 2007年12月04日 06:22 | |
Fixed for Py3k in r59316. Should this gets backported? |
|||
| msg58208 - (view) | Author: Raymond Hettinger (rhettinger) * (Python committer) | Date: 2007年12月05日 06:43 | |
Please post the patch here. I'll take a look to see if it should be backported. |
|||
| msg58213 - (view) | Author: Christian Heimes (christian.heimes) * (Python committer) | Date: 2007年12月05日 12:54 | |
I've backported the fix to 2.5 and trunk. They suffered from the same problem. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:56:28 | admin | set | github: 45894 |
| 2007年12月05日 12:54:32 | christian.heimes | set | status: open -> closed resolution: fixed messages: + msg58213 nosy: + christian.heimes |
| 2007年12月05日 06:43:39 | rhettinger | set | assignee: rhettinger messages: + msg58208 nosy: + rhettinger |
| 2007年12月05日 02:48:33 | alexandre.vassalotti | set | status: open |
| 2007年12月04日 06:22:33 | alexandre.vassalotti | set | status: open -> (no value) messages: + msg58178 |
| 2007年12月04日 05:43:57 | alexandre.vassalotti | create | |