STINNER Victor <vstin...@python.org> added the comment: PyPreConfig.utf8_mode=1 enables the *Python* UTF-8 Mode: * https://docs.python.org/dev/c-api/init_config.html?highlight=pypreconfig_initpythonconfig#c.PyPreConfig.utf8_mode * https://docs.python.org/dev/library/os.html#utf8-mode
> then i 'cout << u8"Chinese中文" << endl; This is C++. C++ is not aware of the Python UTF-8 Mode. You misunderstood the purpose of the Python UTF-8 Mode. std::cout must be configured differently. This is not a Python problem. I suggest to close the issue. ---------- nosy: +vstinner _______________________________________ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue43091> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com