[Python-Dev] Re: Moving away from _Py_IDENTIFIER().

2022年2月03日 14:52:45 -0800

On Wed, Feb 2, 2022 at 11:50 PM Inada Naoki <[email protected]> wrote:
> It would be nice to provide something similar to _PY_IDENTIFIER, but
> designed (and documented) for 3rd party modules like this.
I suppose I'd like to know what the value of _Py_IDENTIFIER() is for
3rd party modules. They can already use PyUnicode_InternFromString()
to get a "global" object and then store it in their module state. I
would not expect _Py_IDENTIFIER() to provide much of an advantage over
that. Perhaps I'm missing something?
If there is a real benefit then we should definitely figure out a good
public API for it (if the current private one isn't sufficient). I
won't be authoring that PEP though. :)
-eric
_______________________________________________
Python-Dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/AVJKKWITJPHUQTE2IXDYBCTQTKVPZPD7/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to