Trouble with modules

Derek Parnell derek at psych.ward
Sat Apr 15 00:40:00 PDT 2006


On Sat, 15 Apr 2006 16:19:36 +1000, Andrew Madigan <amadigan at gmail.com>  
wrote:

> I have a file called HttpCommon.d where I am throwing code that needs to  
> be
> imported by a few files in my project. It contains an enum and a few
> constants. When I try to to import it, I get the following error:
>
> Request.d:5: module HttpCommmon cannot read file 'HttpCommmon.d'
>
> HttpCommon.d (in the same directory) contains:

There is a restriction in D in that one cannot have a module with the same  
name as the directory it appears in. The simple workaround is to rename  
one or the other.

-- 
Derek Parnell
Melbourne, Australia



More information about the Digitalmars-d-learn mailing list