Mercurial > cpython-lru_cache-weakref
diff Objects/dictobject.c @ 74044:393906d020fe 3.2
Small clarification in docstring of dict.update(): the positional argument is not required.
| author | Georg Brandl <georg@python.org> |
|---|---|
| date | Sun, 18 Dec 2011 19:30:55 +0100 |
| parents | df24a8b57148 |
| children | 90572ccda12c e49fdf7d149b |
line wrap: on
line diff
--- a/Objects/dictobject.c Sun Dec 18 19:22:31 2011 +0100 +++ b/Objects/dictobject.c Sun Dec 18 19:30:55 2011 +0100 @@ -1973,9 +1973,9 @@ 2-tuple; but raise KeyError if D is empty."); PyDoc_STRVAR(update__doc__, -"D.update(E, **F) -> None. Update D from dict/iterable E and F.\n" -"If E has a .keys() method, does: for k in E: D[k] = E[k]\n\ -If E lacks .keys() method, does: for (k, v) in E: D[k] = v\n\ +"D.update([E, ]**F) -> None. Update D from dict/iterable E and F.\n" +"If E present and has a .keys() method, does: for k in E: D[k] = E[k]\n\ +If E present and lacks .keys() method, does: for (k, v) in E: D[k] = v\n\ In either case, this is followed by: for k in F: D[k] = F[k]"); PyDoc_STRVAR(fromkeys__doc__,
