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.
Created on 2012年09月23日 23:45 by Joshua.Landau, last changed 2022年04月11日 14:57 by admin. This issue is now closed.
| Messages (2) | |||
|---|---|---|---|
| msg171082 - (view) | Author: Joshua Landau (Joshua.Landau) * | Date: 2012年09月23日 23:45 | |
"a1 = None" is not valid, even though unicodedata.normalize("NFKC", "1") == "1".
One would expect "a1 = None" and "a1 = None" to be equivalent in this case, as with "ai = None" and "ai = None".
I am not sure how many other characters exhibit the same problem.
References:
http://docs.python.org/py3k/reference/lexical_analysis.html#identifiers
http://mail.python.org/pipermail/python-list/2012-September/631420.html
"1" === "\u00b9"
"i" === "\u2071"
|
|||
| msg171089 - (view) | Author: R. David Murray (r.david.murray) * (Python committer) | Date: 2012年09月24日 01:40 | |
I find it unexpected that ai and ai name the same variable, but I suppose that is a consequence of the unicode normalization rules (meaning what I really find surprising is the normalization). As for the '1', its category is No, which does not appear in the list in the identifiers section you link to, while 'i' is Lm, which does. So there is no bug here. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:57:36 | admin | set | github: 60214 |
| 2012年09月25日 21:08:15 | terry.reedy | set | resolution: not a bug |
| 2012年09月24日 01:40:36 | r.david.murray | set | status: open -> closed nosy: + r.david.murray messages: + msg171089 stage: resolved |
| 2012年09月23日 23:45:22 | Joshua.Landau | create | |