Phillip J. Eby wrote: >>A case where this matters is here: http://python.org/sf/1306777 > > I've closed it as invalid; the behavior is as-defined. > > In principle, there *could* be an optimization to avoid rebinding the > lvalue in the case where the __i*__ form did return self. But using it for > the purpose of allowing augmented assignment to tuple members seems dubious > at best, and likely to create confusion about the mutability or lack > thereof of tuples. IMO it's better to have augmented assignment to tuple > members always fail, so that the code has to be a little more specific > about its intent. Okay. I assume that we must accept that s = set() t = (s,) t[0] |= set([1]) changes s in spite of raising TypeError. Reinhold -- Mail address is perfectly valid!
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4