Le mer. 27 mars 2019 à 19:35, Alexander Belopolsky
<alexander.belopol...@gmail.com> a écrit :
> Would you consider making _Py_UnixMain public as well?
>
> It is useful for high level embedding and not trivial for 3rd parties to 
> reimplement.

Right, Py_Main() is causing a lot of practice issues, especially
mojibake because of the C locale coercion (PEP 538) and UTF-8 Mode
(PEP 540): both added in Python 3.7. I added that to the Rationale of
my PEP 587.

I just fixed the mojibake issue in Python 3.8 by disabling C locale
coercion and UTF-8 Mode by default. I'm not sure if nor how Python 3.7
should be fixed in a minor 3.7.x release.

Making _Py_UnixMain() public has already been discussed here:
https://discuss.python.org/t/adding-char-based-apis-for-unix/916

My PEP 587 allows to pass command line arguments as bytes (char*) or
Unicode (wchar_t*).

Ok, I just added Py_UnixMain() to the PEP (just make it part of the public API).

Victor
-- 
Night gathers, and now my watch begins. It shall not end until my death.
_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
https://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to