https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93245
Bug ID: 93245 Summary: std::experimental::filesystem::path::generic_string() doesn't normalize Product: gcc Version: 9.2.1 Status: UNCONFIRMED Severity: normal Priority: P3 Component: libstdc++ Assignee: unassigned at gcc dot gnu.org Reporter: redi at gcc dot gnu.org Target Milestone: --- tmp$ cat gen.cc #include <experimental/filesystem> int main() { if (std::experimental::filesystem::path("///").generic_string() != "/") throw 1; } tmp$ g++ gen.cc -lstdc++fs tmp$ ./a.out terminate called after throwing an instance of 'int' Aborted (core dumped) Adjacent directory separators should be normalized to a single one. There is a test for this function, but it's a copy of some other test and doesn't ever call generic_string()!