unicode as valid naming symbols
ethan at stoneleaf.us
Tue Mar 25 23:47:47 CET 2014
On 03/25/2014 12:29 PM, Mark H Harris wrote:
> On 3/25/14 2:24 PM, MRAB wrote:
>> It's explained in PEP 3131.
>> Basically, a name should to start with a letter (this has been extended
>> to include Chinese characters, etc) or an underscore.
>> λ is a classified as Lowercase_Letter.
>> √ is classified as Math_Symbol.
> Thanks much! I'll note that for improvements. Any unicode symbol (that is not a number) should be allowed as an
No, it shouldn't. Doing so would mean we could not use √ as the square root operator in the future.
Identifiers are made up of letters, numbers, and the underscore. Considering all the unicode letters and unicode
numbers out there, you shouldn't be lacking for names.
More information about the Python-list