Describe the bug
With ../.. only 1 dir is unrolled.
To Reproduce
const char *path = "ab/cd/ef/../../qw";
ghc::filesystem::path srcPath = ghc::filesystem::u8path(path);
std::string destPath = srcPath.lexically_normal().u8string();
Expected behavior
Should produce ab/qw, produces ab/cd/qw.
Attached is a test project.
filesystem_test.zip
UPD:
More test cases:
"\\/\\///\\/" produces //////, expected /.
"a/b/..\\//..///\\/../c\\\\/" produces a/b/c///, expected ../c/.
"a/b/../../../c" produces a/c, expected ../c.
"..a/b/..\\//..///\\/../c\\\\/" produces ..a/b/c///, expected ../c/.
Describe the bug
With
../..only 1 dir is unrolled.To Reproduce
Expected behavior
Should produce
ab/qw, producesab/cd/qw.Attached is a test project.
filesystem_test.zip
UPD:
More test cases:
"\\/\\///\\/"produces//////, expected/."a/b/..\\//..///\\/../c\\\\/"producesa/b/c///, expected../c/."a/b/../../../c"producesa/c, expected../c."..a/b/..\\//..///\\/../c\\\\/"produces..a/b/c///, expected../c/.