On Thu, May 12, 2011 at 5:16 PM, Carl Meyer <c...@oddbird.net> wrote:

>
> On 05/12/2011 06:41 AM, Michal Petrucha wrote:
>
> On Thu, May 12, 2011 at 02:49:03PM +0100, Tom Evans wrote:

> The value of a CompositeField will be represented by an instance of a
> > CompositeValue class. This will be a descendant of tuple and will
> > resemble namedtuple present in Python >= 2.5. It will support
> > iteration, numbered indexing and access to individual field values
> > using attributes corresponding to underlying field names. The order of
> > values will be the same as the order of fields specified in the model
> > definition.
>
> Yes, Tom is right of course - now that Python 2.5 is minimal version, we
> can just use namedtuple.
>

As far as I can tell, namedtuple was added in Python 2.6, not 2.5, so a
compatibility class may still be necessary.

http://docs.python.org/library/collections.html#collections.namedtuple

-- 
Regards,
Ian Clelland
<clell...@gmail.com>

-- 
You received this message because you are subscribed to the Google Groups 
"Django developers" group.
To post to this group, send email to django-developers@googlegroups.com.
To unsubscribe from this group, send email to 
django-developers+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/django-developers?hl=en.

Reply via email to