Changed the way LDC determines if a template instantiation needs to get a definition, seems to speed up compile times quite a bit in some cases.

This commit is contained in:
Tomas Lindquist Olsen
2009-02-04 18:48:03 +01:00
parent a1e6510c39
commit 9bd52922bd
8 changed files with 57 additions and 40 deletions

View File

@@ -607,7 +607,7 @@ void DtoDeclareStruct(StructDeclaration* sd)
sd->ir.irStruct->init = initvar;
gIR->constInitList.push_back(sd);
if (DtoIsTemplateInstance(sd) || sd->getModule() == gIR->dmodule)
if (mustDefineSymbol(sd))
gIR->defineList.push_back(sd);
}