public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "redi at gcc dot gnu.org" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/95048] [9/10/11 Regression] wstring-constructor of std::filesystem::path throws for non-ASCII characters Date: Mon, 11 May 2020 21:14:09 +0000 [thread overview] Message-ID: <bug-95048-4-QoIlmrYteg@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-95048-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=95048 Jonathan Wakely <redi at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |ASSIGNED Summary|wstring-constructor of |[9/10/11 Regression] |std::filesystem::path |wstring-constructor of |throws for non-ASCII |std::filesystem::path |characters |throws for non-ASCII | |characters Assignee|unassigned at gcc dot gnu.org |redi at gcc dot gnu.org --- Comment #3 from Jonathan Wakely <redi at gcc dot gnu.org> --- In libstdc++ filesystem::path uses std::codecvt<wchar_t, char, mbstate_t> to convert from wide character strings in the native wide encoding format (which is set by GCC's -fwide-exec-charset option) to the native encoding for pathnames. The native encoding for pathnames should be UTF-8, but because we use codecvt, which uses wcsnrtombs, we're actually converting to the narrow encoding of the current C locale (which is ASCII by default as Carlos said). So I think libstdc++ needs to use a different conversion from the native wide encoding to UTF-8 (to be independent of the current locale's narrow encoding). This would have changed with r272385 (and r272389 on the gcc-9 branch) which was fixing PR libstdc++/90281.
next prev parent reply other threads:[~2020-05-11 21:14 UTC|newest] Thread overview: 35+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-05-11 7:59 [Bug libstdc++/95048] New: " kontakt at neonfoto dot de 2020-05-11 20:49 ` [Bug libstdc++/95048] " redi at gcc dot gnu.org 2020-05-11 20:59 ` carlos at redhat dot com 2020-05-11 21:14 ` redi at gcc dot gnu.org [this message] 2020-05-11 21:19 ` [Bug libstdc++/95048] [9/10/11 Regression] " redi at gcc dot gnu.org 2020-05-11 21:25 ` redi at gcc dot gnu.org 2020-06-26 12:05 ` rguenth at gcc dot gnu.org 2020-11-12 13:48 ` gcc-bugzilla at m dot chronial.de 2020-11-12 13:58 ` redi at gcc dot gnu.org 2020-11-12 14:02 ` redi at gcc dot gnu.org 2020-11-12 23:49 ` gcc-bugzilla at m dot chronial.de 2021-01-14 8:44 ` rguenth at gcc dot gnu.org 2021-04-19 10:40 ` redi at gcc dot gnu.org 2021-06-01 8:17 ` [Bug libstdc++/95048] [9/10/11/12 " rguenth at gcc dot gnu.org 2021-07-23 12:40 ` gcc-bugzilla at m dot chronial.de 2021-10-19 13:25 ` redi at gcc dot gnu.org 2022-05-27 9:42 ` [Bug libstdc++/95048] [10/11/12/13 " rguenth at gcc dot gnu.org 2022-06-28 10:40 ` jakub at gcc dot gnu.org 2022-10-24 15:09 ` ulf.lorenz at ptvgroup dot com 2022-10-25 11:54 ` redi at gcc dot gnu.org 2022-10-25 12:47 ` ulf.lorenz at ptvgroup dot com 2022-11-11 17:43 ` cvs-commit at gcc dot gnu.org 2022-11-11 17:46 ` [Bug libstdc++/95048] [10/11/12 " redi at gcc dot gnu.org 2022-11-11 17:51 ` redi at gcc dot gnu.org 2022-11-11 22:29 ` cvs-commit at gcc dot gnu.org 2022-11-14 18:34 ` cvs-commit at gcc dot gnu.org 2022-11-22 11:51 ` [Bug libstdc++/95048] [10/11 " ulf.lorenz at ptvgroup dot com 2022-11-22 12:30 ` redi at gcc dot gnu.org 2023-07-07 10:37 ` [Bug libstdc++/95048] [11 " rguenth at gcc dot gnu.org 2023-07-10 15:47 ` cvs-commit at gcc dot gnu.org 2023-07-12 20:04 ` cvs-commit at gcc dot gnu.org 2023-07-12 20:16 ` cvs-commit at gcc dot gnu.org 2023-07-12 20:19 ` cvs-commit at gcc dot gnu.org 2023-07-12 20:23 ` cvs-commit at gcc dot gnu.org 2023-07-12 20:24 ` redi at gcc dot gnu.org
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=bug-95048-4-QoIlmrYteg@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).