commit | 0922d71604522398a0933bf516b5b466a414b772 | [log] [tgz] |
---|---|---|
author | Raymond Hettinger <python@rcn.com> | Wed Feb 07 20:08:22 2007 +0000 |
committer | Raymond Hettinger <python@rcn.com> | Wed Feb 07 20:08:22 2007 +0000 |
tree | 119e1821065dd7cc8ad48267147f5ddc6e8a9261 | |
parent | 814ef237a2c1e42d98fd4c2c3b4afdc201140684 [diff] [blame] |
SF #1615701: make d.update(m) honor __getitem__() and keys() in dict subclasses
diff --git a/Objects/dictobject.c b/Objects/dictobject.c index 5a5f860..901e333 100644 --- a/Objects/dictobject.c +++ b/Objects/dictobject.c
@@ -1306,7 +1306,7 @@ return -1; } mp = (dictobject*)a; - if (PyDict_Check(b)) { + if (PyDict_CheckExact(b)) { other = (dictobject*)b; if (other == mp || other->ma_used == 0) /* a.update(a) or a.update({}); nothing to do */