commit | 20dcf1cb9d0bb719f0f2c88644b8153fd7f75fef | [log] [tgz] |
---|---|---|
author | Raymond Hettinger <python@rcn.com> | Wed Feb 07 20:01:28 2007 +0000 |
committer | Raymond Hettinger <python@rcn.com> | Wed Feb 07 20:01:28 2007 +0000 |
tree | c7b40dd0bab5f2dc184fcfb48a14fc8a7494683c | |
parent | 39e23b2bfa06548ae16d4de2e9a046ee2b4e1d9d [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 */