This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author steven.daprano
Recipients Jáchym Barvínek, steven.daprano
Date 2016-08-25.11:57:34
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1472126254.83.0.493650882332.issue27858@psf.upfronthosting.co.za>
In-reply-to
Content
I had a work mate make this exact same point literally yesterday. He asked me if Python had an identity function, and when I suggested just using `lambda x: x` he grouched that this wasn't sufficiently obvious enough as "identity" is self-explanatory.

(Perhaps for English speakers with a background in mathematics or functional programming.)

I'm not really convinced. Its easier to just write a lambda than to `from functools import identity`, and despite what my workmate thinks, "identity" is not self-evident. Consider that identity could also be a function that returns a person's identifying information. Think about the English usage of "identity theft" and "secret identity", rather than the mathematical meaning.

So I'm at best +0 on this suggestion.
History
Date User Action Args
2016-08-25 11:57:34steven.dapranosetrecipients: + steven.daprano, Jáchym Barvínek
2016-08-25 11:57:34steven.dapranosetmessageid: <1472126254.83.0.493650882332.issue27858@psf.upfronthosting.co.za>
2016-08-25 11:57:34steven.dapranolinkissue27858 messages
2016-08-25 11:57:34steven.dapranocreate