Raymond Hettinger <pyt...@rcn.com> writes: > Hopefully, that discussion can be in a separate thread. > This is really about keeping all the nice O(1) characteristics > of dicts and keeping their straight-forward API while adding > the ability to support nested lookups.
Are you saying the O(1) characteristics are retained even when the contexts are N levels deep? > Sorry for the brush-off, but it would be ashamed if this thread got > immediately hijacked, and I were to lose possible feedback on the > API for nested mappings. The API you suggested looks reasonable although you should also say how to delete a context, how to find the inner contexts of a context, etc. One question: what should c["foo"] = 7 d = c.new_child() del d["foo"] do? -- http://mail.python.org/mailman/listinfo/python-list