Java like class importing

Adam D. Ruppe destructionator at gmail.com
Sun Nov 17 13:41:34 UTC 2019


On Sunday, 17 November 2019 at 09:03:03 UTC, tcak wrote:
> In the main.d, I added the line "import SpacePosition;". And 
> when I compile the main.d, BAM!

I'm of the opinion that you should basically never write 
single-name modules too, since the module namespace is global.

If it was `myproject.SpacePosition` you'd be fine on this and it 
would protect you from other potential conflicts down the line 
too.



More information about the Digitalmars-d mailing list