__setitem__ without position

Ian Kelly ian.g.kelly at gmail.com
Thu Oct 11 18:43:21 EDT 2012


On Thu, Oct 11, 2012 at 4:13 PM, Kevin Anthony
<kevin.s.anthony at gmail.com> wrote:
> I'm not supprised... and understand why it's happening.  I'm asking how to
> get around it.
>
> Basically i'm asking how to override, if i can, the `=`

You cannot override assignment of local variables.  To get around it,
use slicing as Dave suggested, or use an attribute instead of a local
variable.



More information about the Python-list mailing list