mirror of
https://github.com/python/cpython.git
synced 2024-12-01 11:15:56 +01:00
8fc4a91665
of no more than 8 elements cannot fail. listpop(): Take advantage of that its calls to list_resize() and list_ass_slice() can't fail. This is assert'ed in a debug build now, but in an icky way. That is, you can't say: assert(some_call() >= 0); because then some_call() won't occur at all in a release build. So it has to be a big pile of #ifdefs on Py_DEBUG (yuck), or the pleasant: status = some_call(); assert(status >= 0); But in that case, compilers may whine in a release build, because status appears unused then. I'm not certain the ugly trick I used here will convince all compilers to shut up about status (status is always "used" now, as the first (ignored) clause in a comma expression). |
||
---|---|---|
.. | ||
.cvsignore | ||
abstract.c | ||
boolobject.c | ||
bufferobject.c | ||
cellobject.c | ||
classobject.c | ||
cobject.c | ||
complexobject.c | ||
descrobject.c | ||
dictnotes.txt | ||
dictobject.c | ||
enumobject.c | ||
fileobject.c | ||
floatobject.c | ||
frameobject.c | ||
funcobject.c | ||
genobject.c | ||
intobject.c | ||
iterobject.c | ||
listobject.c | ||
listsort.txt | ||
longobject.c | ||
methodobject.c | ||
moduleobject.c | ||
object.c | ||
obmalloc.c | ||
rangeobject.c | ||
setobject.c | ||
sliceobject.c | ||
stringobject.c | ||
structseq.c | ||
tupleobject.c | ||
typeobject.c | ||
unicodectype.c | ||
unicodeobject.c | ||
unicodetype_db.h | ||
weakrefobject.c |