Packages and module import
Adam D. Ruppe
destructionator at gmail.com
Mon Mar 19 17:49:40 UTC 2018
On Monday, 19 March 2018 at 17:29:10 UTC, Russel Winder wrote:
> Especially given there is a module statement at the beginning
> of each module:
It is not especially, it is ONLY because of the module statement.
The directory layout is a convention so tools can find the module
file, but only the module declaration line in the code itself
defines the authoritative name.
> source/libdvbv5_d/dvb_demux.d(35): Error: module linux_dmx from
> file source/libdvbv5_d/linux_dmx.d must be imported with
> 'import linux_dmx;'
Odds are, linux_dmx.d is missing the `module
libdvbv5_d.linux_dmx;` line.
Any import statements and module statements need to use the same
name. The layout in the file system is secondary to this.
More information about the Digitalmars-d-learn
mailing list