GDC Compilation wtih Directory Present
Richard (Rikki) Andrew Cattermole
richard at cattermole.co.nz
Fri Jun 16 06:32:21 UTC 2023
On 16/06/2023 6:26 PM, Murloc wrote:
> Don't you need to provide a full path to these files relatively to the
> directory where the compilation process takes place (Test)?
Yes.
But I suspect you have not written the module statement, which is required.
```d
module pack.file1;
// file1.d
void printlnValueInFile2() {
import std.stdio: writeln;
import pack.file2: value;
writeln(value);
}
```
```d
module pack.file2;
package(pack) int value = -120;
```
Its also a good habit to write the package attribute with explicit
package(s).
More information about the Digitalmars-d-learn
mailing list