Issue 36198: Misleading in library/sets document (original) (raw)
Issue36198
Created on 2019-03-05 14:34 by DeadmanWalking, last changed 2022-04-11 14:59 by admin. This issue is now closed.
Messages (4) | ||
---|---|---|
msg337192 - (view) | Author: Han (DeadmanWalking) | Date: 2019-03-05 14:34 |
Doc/library/sets.rst said operation s.update(t)'s result is "return set s with elements added from t". But update()'s return value is None. I think change it to "set s with elements added from t" would be better. So are operations intersection_update(), difference_update(), and symmetric_difference_update(). | ||
msg337206 - (view) | Author: Karthikeyan Singaravelan (xtreak) * ![]() |
Date: 2019-03-05 15:27 |
To add to this is actually present in sets module documentation which has been deprecated since 2.6 though the report is true that the methods don't return a set. Link : https://docs.python.org/2/library/sets.html#set-objects | ||
msg337276 - (view) | Author: Josh Rosenberg (josh.r) * ![]() |
Date: 2019-03-06 03:57 |
The "returns" bit is accurate when referring to the in-place operator overloads (__ior__), so those lines may have been written referring to the overloads described on the same line (they shouldn't have been written that way, but that would explain why only the methods with in-place overload equivalents use the word "returns"). Either way, sets was deprecated in 2.6, largely pointless in every version but 2.3 (module added in 2.3, built-in set/frozenset types added 2.4), and gone in 3.0+ (and 2.7 is EOL within the year). Do we even do doc updates for stuff this dead? | ||
msg337280 - (view) | Author: Han (DeadmanWalking) | Date: 2019-03-06 05:24 |
Thanks, I didn't notice the Deprecated sign on the Sets page. |
History | |||
---|---|---|---|
Date | User | Action | Args |
2022-04-11 14:59:12 | admin | set | github: 80379 |
2019-03-06 05:24:43 | DeadmanWalking | set | status: open -> closedmessages: + stage: resolved |
2019-03-06 03:57:00 | josh.r | set | nosy: + josh.rmessages: + |
2019-03-05 15:27:56 | xtreak | set | nosy: + rhettinger, xtreakmessages: + |
2019-03-05 14:34:50 | DeadmanWalking | create |