Direntries seems to on other drives. (windows)

Vladimir Panteleev via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sat Apr 2 00:54:24 PDT 2016


On Friday, 1 April 2016 at 02:05:23 UTC, Taylor Hillegeist wrote:

> Even though i just checked for a valid path.

> [...]

> 	if(!args[1].buildNormalizedPath.isValidPath){writeln("Path is 
> invalid! "); return;}

 From https://dlang.org/library/std/path/is_valid_path.html :

> It does *not* check whether the path points to an existing file 
> or directory; use std.file.exists for this purpose.

You are using the wrong function for the job.

The simple explanation is that the path you specified doesn't 
actually exist.


More information about the Digitalmars-d-learn mailing list