Message258921
| Author | serhiy.storchaka |
|---|---|
| Recipients | alexandre.vassalotti, fdrake, serhiy.storchaka, vstinner |
| Date | 2016-01-25.20:53:06 |
| SpamBayes Score | -1.0 |
| Marked as misclassified | Yes |
| Message-id | <1453755186.26.0.578500471201.issue26202@psf.upfronthosting.co.za> |
| In-reply-to |
| Content | |
|---|---|
The range() object is immutable, but is not atomic, and copy.deepcopy() shouldn't return it unchanged. >>> class I(int): pass # mutable index ... >>> import copy >>> r = range(I(10)) >>> r2 = copy.deepcopy(r) >>> r.stop.attr = 'spam' >>> r2.stop.attr 'spam' This is Python 3 only issue because in 2.7 the xrange() object doesn't exposes start/stop/step attributes. Proposed patch fixes the copy module. |
|
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2016-01-25 20:53:06 | serhiy.storchaka | set | recipients: + serhiy.storchaka, fdrake, vstinner, alexandre.vassalotti |
| 2016-01-25 20:53:06 | serhiy.storchaka | set | messageid: <1453755186.26.0.578500471201.issue26202@psf.upfronthosting.co.za> |
| 2016-01-25 20:53:06 | serhiy.storchaka | link | issue26202 messages |
| 2016-01-25 20:53:06 | serhiy.storchaka | create | |