Bart Ogryczak a écrit :
> On 2008-01-22, citizen Bruno Desthuilliers testified:
>>>                     from copy import copy
>>>                     ### see also deepcopy
>>>                     self.lst = copy(val)
>> What makes you think the OP wants a copy ?
> 
> I´m guessing he doesn´t want to mutate original list, while changing 
> contents of self.lst.

Once again: what makes you think so ?

This is a design choice depending on the concrete use case and context - 
which we don't know zilch about - and by no mean the default behaviour.

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to