threads
Tim Peters
tim_one at email.msn.com
Fri Jun 4 21:42:21 EDT 1999
[Hrvoje Niksic]
> ...
> Ironically, when I first saw "tuples" in Python, I assumed they were
> invented to speed up threading because you don't need to lock access
> to immutable structures. (The same applies to immutable strings.)
> Boy, was I wrong. :-(
Besides, immutable structures are still mutable "under the covers": in
particular, their refcounts get boosted and dropped all the time. That also
needs to be atomic.
OTOH, you weren't wrong! Guido is well aware of the optimizations that
*may* someday apply thanks to immutability. That not all coneivable such
have been implemented yet is merely evidence that time has extent <wink>.
the-poor-man's-so-depressed-about-whitespace-he-can-barely-get-
thru-the-day-ly y'rs - tim
More information about the Python-list
mailing list