In the section on the __reduce__ API, the description of the state

argument used an implicit __setitem__ in the last-resort case, but
the implementation actually uses setattr.  Repaired the pseudocode
to match reality.  Doc bug spotted by Jim Fulton.
This commit is contained in:
Tim Peters 2003-08-04 19:08:57 +00:00
parent 6e249d8955
commit ce48e1a732
1 changed files with 1 additions and 1 deletions

View File

@ -206,7 +206,7 @@ Extended __reduce__ API
or, if the update() call fails,
for k, v in state.items():
obj[k] = v
setattr(obj, k, v)
listitems Optional, and new in this PEP.
If this is not None, it should be an iterator (not a