diff options
author | Raymond Hettinger <python@rcn.com> | 2004-03-09 08:04:33 +0000 |
---|---|---|
committer | Raymond Hettinger <python@rcn.com> | 2004-03-09 08:04:33 +0000 |
commit | f889e10c198864ec5e14bb5f93d63f5b1ce21cc8 (patch) | |
tree | e2bd49a2c2f7eeeecafe2072a00eb658687b33e5 /Objects/tupleobject.c | |
parent | 9168c70438a4f95099dc77377ceb11017bd1ff36 (diff) | |
download | cpython-git-f889e10c198864ec5e14bb5f93d63f5b1ce21cc8.tar.gz |
Optimize slice assignments.
* Replace sprintf message with a constant message string -- this error
message ran on every invocation except straight deletions but it was
only needed when the rhs was not iterable. The message was also
out-of-date and did not reflect that iterable arguments were allowed.
* For inner loops that do not make ref count adjustments, use memmove()
for fast copying and better readability.
* For inner loops that do make ref count adjustments, speed them up by
factoring out the constant structure reference and using vitem[] instead.
Diffstat (limited to 'Objects/tupleobject.c')
0 files changed, 0 insertions, 0 deletions