On Thu, 03 Sep 2009 17:10:12 +, Kreso wrote:
> I would prefer that resulting object m belonged to myclist class.
> How to obtain such behaviour? Must I somehow implement __getslice__
> method myself?
Yes; you should also implement __getitem__(), as this is used for extended
slices.
--
http:
Kreso wrote:
[...]
> I would prefer that resulting object m belonged to myclist class.
I forgot to add that mylist instances in my case have some attributes (that's
why I need special container class in the first place) which should be
preserved after splicing.
In my simple understaning of pyth
On 9/3/2009 10:10 AM Kreso said...
I am subclassing list class and it basically works, but I don't
understand why after splicing these mylist objects I don't get
returned mylist objects. What I get are list objects:
I would prefer that resulting object m belonged to myclist class.
How to obtai