diff options
author | Neal Norwitz <nnorwitz@gmail.com> | 2007-04-16 06:59:13 +0000 |
---|---|---|
committer | Neal Norwitz <nnorwitz@gmail.com> | 2007-04-16 06:59:13 +0000 |
commit | e6e383f4984c71a0126743474ac4ca209dd946b6 (patch) | |
tree | 457b3db806e489a59f0ff9e9881e3aa89aa5c791 /Objects/dictobject.c | |
parent | 8d61db5a004f04f7cfc2105f9c092ba97bc08ce4 (diff) | |
download | cpython-git-e6e383f4984c71a0126743474ac4ca209dd946b6.tar.gz |
Revert SF #1615701 (rev 53655): dict.update() does *not* call __getitem__() or
keys() if subclassed. This is to remain consistent with 2.5.
See discussion here:
http://mail.python.org/pipermail/python-dev/2007-April/072565.html
Diffstat (limited to 'Objects/dictobject.c')
-rw-r--r-- | Objects/dictobject.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Objects/dictobject.c b/Objects/dictobject.c index bc3cd53ebe..af0d6f37ae 100644 --- a/Objects/dictobject.c +++ b/Objects/dictobject.c @@ -1352,7 +1352,7 @@ PyDict_Merge(PyObject *a, PyObject *b, int override) return -1; } mp = (dictobject*)a; - if (PyDict_CheckExact(b)) { + if (PyDict_Check(b)) { other = (dictobject*)b; if (other == mp || other->ma_used == 0) /* a.update(a) or a.update({}); nothing to do */ |