Why are there no ordered dictionaries?

Ben Sizer kylotan at gmail.com
Mon Nov 21 05:55:04 EST 2005


Fredrik Lundh wrote:
> bonono at gmail.com wrote:
> > Using the same logic, we don't need types other than string in a  DBMS
> > as we can always convert a string field into some other types when it
> > is needed.
>
> No, that's not the same logic.  The dict() in my example doesn't convert be-
> tween data types; it provides a new way to view an existing data structure.

This is interesting; I would have thought that the tuple is read and a
dictionary created by inserting each pair sequentially. Is this not the
case?

-- 
Ben Sizer




More information about the Python-list mailing list