[PATCH] codecvt<wchar_t, char, mbstate_t> support for UTF-8
Pétur Runólfsson
peturr02@ru.is
Sun Jan 26 19:11:00 GMT 2003
Nathan Myers wrote:
> Am I mistaken in thinking that this introduces even more
> thread-unsafe
> code sequences into the library?
I was under the impression that __use_locale only changes the locale for
the current thread, so this should be thread-safe on glibc 2.3 systems.
Is this correct?
You are of course right that MB_CUR_MAX is not thread-safe in general
(since it depends on the global locale set by setlocale). This however
seems to be a general problem with the generic locale implementation
(including codecvt<wchar_t, char, mbstate_t>::do_in and do_out).
Regards,
Petur
More information about the Libstdc++
mailing list