AFAK it was in whatever PEP introduced Unicode identifiers. On Jun 3, 2017 11:24 PM, "Nick Coghlan" <ncogh...@gmail.com> wrote:
> On 4 June 2017 at 05:02, Dan Sommers <d...@tombstonezero.net> wrote: > > On Sat, 03 Jun 2017 17:45:43 +0000, Brett Cannon wrote: > > > >> On Fri, 2 Jun 2017 at 15:56 Guido van Rossum <gu...@python.org> wrote: > >> > >>> I would love to show how easy it is to write > >>> > >>> from math import pi as π, gamma as Γ > > > > [...] > > > >>> but I had to cheat by copying from the OP since I don't know how to > type > >>> these (and even if you were to tell me how I'd forget tomorrow). So, I > am > >>> still in favor of the rule "only ASCII in the stdlib". > >> > >> Since this regularly comes up, why don't we add a note to the math > module > >> that you can do the above import(s) to bind various mathematical > constants > >> to their traditional symbol counterparts? ... > > > > Because in order to add that note to the math module, you have to > > violate the "only ASCII in the stdlib" rule. ;-) > > The ASCII-only restriction in the standard library is merely "all > public APIs will use ASCII-only identifiers", rather than "We don't > allow the use of Unicode anywhere" (Several parts of the documentation > would be rather unreadable if they were restricted to ASCII > characters). > > However, clarifying that made me realise we've never actually written > that down anywhere - it's just been an assumed holdover from the fact > that Python 2.7 is still being supported, and doesn't allow for > Unicode identifiers in the first place. > > https://github.com/python/peps/pull/285 is a PR to explicitly document > the standard library API restriction in the "Names to Avoid" part of > PEP 8. > > Cheers, > Nick. > > -- > Nick Coghlan | ncogh...@gmail.com | Brisbane, Australia > _______________________________________________ > Python-ideas mailing list > Python-ideas@python.org > https://mail.python.org/mailman/listinfo/python-ideas > Code of Conduct: http://python.org/psf/codeofconduct/ >
_______________________________________________ Python-ideas mailing list Python-ideas@python.org https://mail.python.org/mailman/listinfo/python-ideas Code of Conduct: http://python.org/psf/codeofconduct/