rdmd bug?
CrypticMetaphor
CrypticMetaphor88 at gmail.com
Sun Dec 19 16:24:02 PST 2010
Hello, I'm being driven nuts by this problem, I don't know 100% if it's
it's a bug or if it's intended behavior, I'm new to D( also new to
reporting bugs ) so I can't really tell.
Anyway, the problem is, if I call rdmd from outside the folder in which
the main source resides in, and main includes another file in that
folder, I get an error.
example:
...\projectfolder\src\main.d
...\projectfolder\src\test.d
// main.d
module main;
import test.d;
void main()
{
hello();
}
// end main.d
// test.d
module test.d;
import std.stdio;
void hello()
{
writeln("Hello");
}
// end test.d
// If I'm in a shell, and I do this, I get an error:
...\projectfolder>rdmd src\main.d
src\main.d(2): Error: module test is in file 'test.d' which cannot be read
import path[0] = C:\D\dmd2\windows\bin\..\..\src\phobos
import path[1] = C:\D\dmd2\windows\bin\..\..\src\druntime\import
// but if I do this, it works:
...\projectfolder\src>rdmd main.d
...\projectfolder\src>Hello world
// also works
...\projectfolder\src>dmd main.d test.d
Anyway, I want to be able to compile with rdmd from a different folder,
is this a bug? or should I use a different tool? :-S
*aahhh*
Other info:
OS: Windows
rdmd build 20101220
dmd: 2.050
More information about the Digitalmars-d-learn
mailing list