Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #59102 > unrolled thread
| Started by | random832@fastmail.us |
|---|---|
| First post | 2013-11-11 16:40 -0500 |
| Last post | 2013-11-11 16:40 -0500 |
| Articles | 1 — 1 participant |
Back to article view | Back to comp.lang.python
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
Re: 'isimmutable' and 'ImmutableNester' random832@fastmail.us - 2013-11-11 16:40 -0500
| From | random832@fastmail.us |
|---|---|
| Date | 2013-11-11 16:40 -0500 |
| Subject | Re: 'isimmutable' and 'ImmutableNester' |
| Message-ID | <mailman.2399.1384206051.18130.python-list@python.org> |
> A built-in function 'isimmutable()' shall tell efficiently whether the > object > of concern is mutable or not. What's the benefit over attempting to hash() the object? copy.deepcopy already has special case for int, string, and tuples (including tuples that do and do not have mutable members) - could what you need be accomplished by overriding __copy__ and __deepcopy__ in your custom class to return itself if it is immutable?
Back to top | Article view | comp.lang.python
csiph-web