On Sep 12, 8:42 am, Steven D'Aprano <[EMAIL PROTECTED] cybersource.com.au> wrote: > On Wed, 12 Sep 2007 07:33:45 +0000, Mark Summerfield wrote: > > I feel that Python lacks one useful data structure: an ordered > > dictionary. > > > I find such data structures v. useful in C++. > > [snip] > > Personally, I've never missed an ordered dict. What do people use them > for?
I once had a GUI that displayed the contents of a dict as a tree. The user could add entries, and the entries would display at the end. Hence, the ordered dict. I could have kept the order separately, but what was the point? I just whipped up a homemade ordered dict class, it worked fine, and I didn't have to worry about keeping them synchronized. Carl Banks -- http://mail.python.org/mailman/listinfo/python-list