STINNER Victor <vstin...@redhat.com> added the comment:

Maybe the Python documentation can be enhanced to document functions which are 
known to have a side-effect "process-wide" vs "thread-safe" functions. For 
example, signal.pthread_sigmark() affects the current thread, wheras 
locale.setlocale() is process-wide.

See "POSIX Safety Concepts" of the glibc:

https://www.gnu.org/software/libc/manual/html_node/POSIX-Safety-Concepts.html#POSIX-Safety-Concepts

Example with setlocale, "MT-Unsafe":

https://www.gnu.org/software/libc/manual/html_node/Setting-the-Locale.html

----------
nosy: +vstinner

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue35275>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to