This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: Allow keyword args in dict.update()
Type: Stage:
Components: Interpreter Core Versions: Python 2.3
Status: closed Resolution: rejected
Dependencies: Superseder:
Assigned To: Nosy List: jvr, loewis, rhettinger
Priority: normal Keywords: patch

Created on 2002-11-25 14:06 by jvr, last changed 2022-04-10 16:05 by admin. This issue is now closed.

File name Uploaded Description Edit
dict.update.patch jvr, 2002-11-25 14:06 allow keyword args in dict.update()
Messages (4)
msg41767 - (view) Author: Just van Rossum (jvr) * (Python triager) Date: 2002-11-25 14:06
Now that patch #642500 is in, it only seems logical to
also allow keyword args in dict.update(). This patch
simply reuses dict_init(), so d.update(seq_of_items)
also works. I'm not conviced of the neccessity of this
patch, but the implementation is very simple. Doc and
test will follow (also: gladly accepted ;-) if the idea
is accepted.

Side effect: d.update() (no args!) raises no exception
msg41768 - (view) Author: Martin v. Löwis (loewis) * (Python committer) Date: 2002-11-27 20:58
Logged In: YES 

What documentation and test suite changes do you propose?
msg41769 - (view) Author: Raymond Hettinger (rhettinger) * (Python committer) Date: 2002-12-29 05:24
Logged In: YES 

This would be a nice idea for completeness but it is neither 
necessary nor desirable.  d[k]=v is a faster, clearer, one-
way-to-do-it alternative.

The side-effect is also undesirable.  I'm -0 on this one.
msg41770 - (view) Author: Just van Rossum (jvr) * (Python triager) Date: 2002-12-29 09:01
Logged In: YES 

I'd completely forgotten about this patch. I has little use
indeed. Closed & Rejected.
Date User Action Args
2022-04-10 16:05:56adminsetgithub: 37532
2002-11-25 14:06:08jvrcreate