UncanonicalizedIter can generate invalid paths if the path has a dash or hyphen within the first 4 characters.
Example, my-tool produces:
my/-t/my-tool
my/_t/my-tool
my/-t/my_tool
my/_t/my_tool
The second and third paths are invalid because the directory prefix does not match the name of the file.
I think the UncanonicalizedIter needs to iterate over the fs_name before it has been converted to path.
UncanonicalizedItercan generate invalid paths if the path has a dash or hyphen within the first 4 characters.Example,
my-toolproduces:my/-t/my-toolmy/_t/my-toolmy/-t/my_toolmy/_t/my_toolThe second and third paths are invalid because the directory prefix does not match the name of the file.
I think the UncanonicalizedIter needs to iterate over the
fs_namebefore it has been converted to path.