diff dmd/TypeStruct.d @ 85:8e69d041a99d

Previous commit didn't compile. Fixed.
author Eldar Insafutdinov <e.insafutdinov@gmail.com>
date Mon, 30 Aug 2010 16:16:30 +0100
parents be2ab491772e
children e28b18c23469
line wrap: on
line diff
--- a/dmd/TypeStruct.d	Mon Aug 30 16:12:19 2010 +0100
+++ b/dmd/TypeStruct.d	Mon Aug 30 16:16:30 2010 +0100
@@ -516,7 +516,7 @@
 		StructDeclaration s = sym;
 
 		sym.size(Loc(0));		// give error for forward references
-		foreach (Dsymbol sm; s.fields)
+		foreach (VarDeclaration sm; s.fields)
 		{
 			Declaration d = sm.isDeclaration();
 			if (d.storage_class & STC.STCref || d.hasPointers())
@@ -542,9 +542,8 @@
 				{	/* Check all the fields. If they can all be converted,
 					 * allow the conversion.
 					 */
-					foreach (Dsymbol s; sym.fields)
+					foreach (VarDeclaration v; sym.fields)
 					{   
-						VarDeclaration v = s.isVarDeclaration();
 						assert(v && v.storage_class & STCfield);
 
 						// 'from' type