Mercurial > projects > ldc
diff dmd2/struct.c @ 1526:54b3c1394d62
Merged dmdfe 2.031.
author | Robert Clipsham <robert@octarineparrot.com> |
---|---|
date | Tue, 07 Jul 2009 02:26:11 +0100 |
parents | f62347c22d81 |
children |
line wrap: on
line diff
--- a/dmd2/struct.c Mon Jul 06 23:57:27 2009 +0100 +++ b/dmd2/struct.c Tue Jul 07 02:26:11 2009 +0100 @@ -46,7 +46,6 @@ stag = NULL; sinit = NULL; #endif - scope = NULL; isnested = 0; vthis = NULL; @@ -70,7 +69,7 @@ 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::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 @@ } parent = sc->parent; + type = type->semantic(loc, sc); #if STRUCTTHISREF handle = type; #else