
Oct. 26, 2003
5:51 p.m.
On Sunday 26 October 2003 06:34 pm, Raymond Hettinger wrote: ...
b to be Sets; however, a.union(b) allows b to be any iterable. The matches the distinction between list.__iadd__() and list.extend() where the former requires a list argument and the latter does not.
What distinction...?
x=range(3) x.__iadd__('foo') [0, 1, 2, 'f', 'o', 'o'] x [0, 1, 2, 'f', 'o', 'o']
did you mean list.__add__()...? list.__iadd__ IS just as permissive as list.extend, it seems to me. Alex