I've got errors, and I wasn't sure about reporting them, because there are
so many, and they're probably all my fault, but some are ICEs.


file program.d:

import subdir.first_module;
import subdir: second_module;

void main() {
    assert(first_ok());
    assert(second_module.second_ok());
}


file subdir/package.d:

module subdira;

public import second_module;


file subdir/first_module.d:

bool first_ok()
{
    return true;
}


file subdir/second_module.d:

bool second_ok()
{
    return true;
}


$ gdc program.d -Isubdir subdir/first_module.d subdir/second_module.d cc1d: ../../src/gcc/d/dfrontend/import.c:144: void Import::load(Scope*): Assertion `mod->isPackageFile == (p->isPkgMod == PKGmodule)' failed.
cc1d: internal compiler error: Aborted
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-6/README.Bugs> for instructions.

Then change the line in subdir/package.d "module subdira;" to "module subdir;"
That should fix it!

$ gdc program.d -Isubdir subdir/first_module.d subdir/second_module.d program.d:1:8: internal compiler error: in visit, at d/imports.cc:47
 import subdir.first_module;
        ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-6/README.Bugs> for instructions.


I tried signing in at Bugzilla, which I've used before, but it didn't accept my password, and when I asked to reset my password, it said it sent an email, but I didn't receive an email. Maybe you're not using the same Bugzilla as some other project.

Reply via email to