On 6/2/2017 7:56 PM, Ivan Levkivskyi wrote:
On 3 June 2017 at 01:29, Guido van Rossum <gu...@python.org <mailto:gu...@python.org>> wrote:

    Are those characters not considered Unicode letters? Maybe we could
    add their category to the allowed set?


Yes, they are not considered letters, they are in category Sm.

I presume that is Symbol - math.

Unfortunately, +, -, |, and other symbol that clearly should not be in identifiers are also in this category, so we cannot add the whole category. It is possible to include particular ranges,

Having to test ranges will slow down identifier recognition.

but there should be a discussion
about what exactly can/should be included.

I believe the current python definition of 'identifier' is taken from the Unicode Standard for default identifiers. Any change would have to be propagated to regex engines, IDEs, and anything else that parses python. I suggest that you ask Martin Loewis for his opinion on changing the identifier definition.

--
Terry Jan Reedy

_______________________________________________
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ideas
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to