Re: += append class operator

2006-04-19 Thread schwehr
Awesome. Thanks! -kurt -- http://mail.python.org/mailman/listinfo/python-list

Re: += append class operator

2006-04-19 Thread Fredrik Lundh
[EMAIL PROTECTED] wrote: > This is probably a FAQ, but is there an operator mapping for += for > classes? obj.__iadd__(other) > Or does a += b get converted to a = a + b? only if __iadd__ is not defined. > I would like to make this operator faster for the BitVector class, but > I don't se

+= append class operator

2006-04-19 Thread schwehr
Hi All, This is probably a FAQ, but is there an operator mapping for += for classes? Or does a += b get converted to a = a + b? I would like to make this operator faster for the BitVector class, but I don't see += in http://docs.python.org/lib/operator-map.html I could always create an append m