import std conflicts with d.std

clayasaurus clayasaurus at gmail.com
Tue Jul 11 10:47:57 PDT 2006


J C Calvarese wrote:
> The following code gives this error message, but I think it should work:
> v.d(3): import std conflicts with d.std at d.d(3)
> 
> 
> 
> [c.d]
> module c;
> 
> import v;
> import d;
> 
> V start;
> std.stream.File file;
> 
> 
> 
> [d.d]
> module d;
> 
> import std.c.windows.windows;
> 
> 
> 
> [v.d]
> module v;
> 
> import std.stream;
> struct V{}
> 
> 
> 
> [build.bat]
> dmd c.d -c
> pause
> 
> 
> 
> And, yes, it compiles fine if I change the last line of c.d to:
> "File file;"
> 
> Workarounds are great, but I think it should either compile as written 
> or give a more detailed explanation in the error message.
> 
> By the way, this is from an issue discovered by clayasaurus in 
> http://www.digitalmars.com/drn-bin/wwwnews?digitalmars.D/8423
> 
> I'm sure I posted an eerily similar bug report before, but I can't find 
> it, so maybe I dreamed the whole thing.
> 

I still get bitten by this regularly and come back here to see the 
workarounds, hence this post.

~ Clay



More information about the Digitalmars-d-bugs mailing list