On Fri, Jun 21, 2019 at 1:23 AM Steve Dower <steve.do...@python.org> wrote:
>
> What benefit would this provide?

It is faster, of course.

The whole benefit will be not significant for now.
But I'm thinking of making _Py_Identifier public (CPython API) in the future.
If we make it public, breaking change is hard after that.

So I want to confirm it's intended that _Py_Identifier support non-ASCII.
If it's not intended, more strict equals to more possibility of
optimization in the future.


> And why is a non-ASCII identifier not
> practical?
>

Hm, I might wrong about the nuance of the word "practical".
I meant it's very uncommon.   It's because:

* While we allow non-ASCII identifier in Python, we don't use them in core.
* Most usage of _Py_Identifier creates C variable named like C PyId_foo.
* There is _Py_static_string which doesn't create variable named like PyId_foo,
  but all usage in CPython uses ASCII only, and _Py_Identifier is still private.

-- 
Inada Naoki  <songofaca...@gmail.com>
_______________________________________________
Python-Dev mailing list -- python-dev@python.org
To unsubscribe send an email to python-dev-le...@python.org
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/python-dev@python.org/message/PTJEUFDKEIUSUFUCEQWWVRCERVQENQFA/

Reply via email to