[Python-ideas] suggestion about the sort() function of the list instance
Greg Ewing
greg.ewing at canterbury.ac.nz
Wed Mar 1 14:41:21 EST 2017
Stéfane Fermigier wrote:
> Cf. https://martinfowler.com/bliki/CommandQuerySeparation.html
Python's convention is less extreme than this, since it only applies
to methods that, under the conventions of some other languages, would
return self to facilitate chaining. There's no rule against a mutating
method returning some other value if that's convenient.
--
Greg
More information about the Python-ideas
mailing list