[Python-Dev] Bad idea: dict(kwargs)

Aahz aahz@pythoncraft.com
Fri, 4 Jul 2003 13:07:09 -0400


In http://mail.python.org/pipermail/python-dev/2003-June/036502.html
Bengt Richter made a strong argument that dict(kwargs) causes problems
for subclasses of dict.  There was no response.  After thinking about
it, I'm forced to agree that this is poor design.

Guido, please Pronounce on this officially.  I realize that it's a bit
late to remove, but you've always expressed distaste for adding features
that are easily expressed with a one-liner:

    def kw_dict(**kwargs):
        return kwargs
-- 
Aahz (aahz@pythoncraft.com)           <*>         http://www.pythoncraft.com/

Usenet is not a democracy.  It is a weird cross between an anarchy and a
dictatorship.