Merged dmdfe 2.031.

This commit is contained in:
Robert Clipsham
2009-07-07 02:26:11 +01:00
parent e5b7c25597
commit b73e45940a
40 changed files with 1432 additions and 377 deletions

View File

@@ -46,7 +46,6 @@ AggregateDeclaration::AggregateDeclaration(Loc loc, Identifier *id)
stag = NULL;
sinit = NULL;
#endif
scope = NULL;
isnested = 0;
vthis = NULL;
@@ -70,7 +69,7 @@ enum PROT AggregateDeclaration::prot()
void AggregateDeclaration::semantic2(Scope *sc)
{
//printf("AggregateDeclaration::semantic2(%s)\n", toChars());
if (scope)
if (scope && members)
{ error("has forward references");
return;
}
@@ -89,9 +88,10 @@ void AggregateDeclaration::semantic2(Scope *sc)
void AggregateDeclaration::semantic3(Scope *sc)
{ int i;
// LDC
#if IN_LLVM
if (!global.params.useAvailableExternally)
availableExternally = false;
#endif
//printf("AggregateDeclaration::semantic3(%s)\n", toChars());
if (members)
@@ -288,6 +288,7 @@ void StructDeclaration::semantic(Scope *sc)
}
parent = sc->parent;
type = type->semantic(loc, sc);
#if STRUCTTHISREF
handle = type;
#else