@@ -4695,7 +4695,6 @@ private struct DirIteratorImpl
4695
4695
bool toNext (bool fetch, scope WIN32_FIND_DATAW * findinfo) @trusted
4696
4696
{
4697
4697
import core.stdc.wchar_ : wcscmp;
4698
- import std.string : chompPrefix;
4699
4698
4700
4699
if (fetch)
4701
4700
{
@@ -4712,7 +4711,7 @@ private struct DirIteratorImpl
4712
4711
popDirStack();
4713
4712
return false ;
4714
4713
}
4715
- _cur = DirEntry (_stack[$- 1 ].dirpath.chompPrefix(_pathPrefix) , findinfo);
4714
+ _cur = DirEntry (_stack[$- 1 ].dirpath, findinfo);
4716
4715
return true ;
4717
4716
}
4718
4717
@@ -4757,8 +4756,6 @@ private struct DirIteratorImpl
4757
4756
4758
4757
bool next () @trusted
4759
4758
{
4760
- import std.string : chompPrefix;
4761
-
4762
4759
if (_stack.length == 0 )
4763
4760
return false ;
4764
4761
@@ -4768,7 +4765,7 @@ private struct DirIteratorImpl
4768
4765
if (core.stdc.string.strcmp (&fdata.d_name[0 ], " ." ) &&
4769
4766
core.stdc.string.strcmp (&fdata.d_name[0 ], " .." ))
4770
4767
{
4771
- _cur = DirEntry (_stack[$- 1 ].dirpath.chompPrefix(_pathPrefix) , fdata);
4768
+ _cur = DirEntry (_stack[$- 1 ].dirpath, fdata);
4772
4769
return true ;
4773
4770
}
4774
4771
}
@@ -4798,21 +4795,9 @@ private struct DirIteratorImpl
4798
4795
4799
4796
this (string pathname, SpanMode mode, bool followSymlink)
4800
4797
{
4801
- import std.path : absolutePath, isAbsolute;
4802
-
4803
4798
_mode = mode;
4804
4799
_followSymlink = followSymlink;
4805
4800
4806
- if (! pathname.isAbsolute)
4807
- {
4808
- const pathnameRel = pathname;
4809
- alias pathnameAbs = pathname;
4810
- pathname = pathname.absolutePath;
4811
-
4812
- const offset = pathnameAbs.length - pathnameRel.length;
4813
- _pathPrefix = pathnameAbs[0 .. offset];
4814
- }
4815
-
4816
4801
if (stepIn(pathname))
4817
4802
{
4818
4803
if (_mode == SpanMode.depth)
0 commit comments