[Python-ideas] Support other dict types for type.__dict__
Victor Stinner
victor.stinner at haypocalc.com
Mon Feb 27 19:55:50 CET 2012
More information about the Python-ideas mailing list
Mon Feb 27 19:55:50 CET 2012
- Previous message: [Python-ideas] Support other dict types for type.__dict__
- Next message: [Python-ideas] Support other dict types for type.__dict__
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
2012/2/27 Oleg Broytman <phd at phdru.name>: > On Mon, Feb 27, 2012 at 06:35:57PM +0000, Rob Cliffe wrote: >> I suggested a "mutable" attribute some time ago. >> This could lead to finally doing away with one of Python's FAQs: Why >> does python have lists AND tuples? They could be unified into a >> single type. > > The main difference between lists and tuples is not mutability but > usage: lists are for a (unknown) number of similar items (a list of > messages, e.g.), tuples are for a (known) number of different items at > fixed positions (an address is a tuple of (country, city, street > address), for example). And tuple doesn't have append, extend, remove, ... methods. Victor
- Previous message: [Python-ideas] Support other dict types for type.__dict__
- Next message: [Python-ideas] Support other dict types for type.__dict__
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-ideas mailing list