https://issues.dlang.org/show_bug.cgi?id=10209
Timothee Cour <timothee.co...@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |REOPENED CC| |timothee.co...@gmail.com Resolution|WONTFIX |--- --- Comment #3 from Timothee Cour <timothee.co...@gmail.com> --- > That's expected - __FILE__ returns a relative path whereas if you set -J/ it > would now require an absolute on. That is incorrect, as you can check with `pragma(msg, __FILE__);` __FILE__ returns either a relative or absolute path depending on how the file is given on command line. As you can see in my original example, `dmd -J/ /path/to//file.d` __FILE__ will be absolute. > 4) -J/ is quite an anti-pattern That's irrelevant, I could've used any other path that contains a `//`, eg: `dmd -J. -o- .//main.d` also fails Like I said in the original post (please re-read more carefully): "problem when a path argument given to dmd contains a '//' instead of '/':" Note that -I has no problems with paths that contains a `//`. --