diff dmd/NewExp.d @ 84:be2ab491772e

Expressions -> Vector!Expression
author Eldar Insafutdinov <e.insafutdinov@gmail.com>
date Mon, 30 Aug 2010 16:12:19 +0100
parents 2e2a5c3f943a
children 39648eb578f6
line wrap: on
line diff
--- a/dmd/NewExp.d	Mon Aug 30 18:42:04 2010 +0400
+++ b/dmd/NewExp.d	Mon Aug 30 16:12:19 2010 +0100
@@ -261,7 +261,7 @@
 				Expression e = new IntegerExp(loc, cd.size(loc), Type.tsize_t);
 				if (!newargs)
 					newargs = new Expressions();
-				newargs.shift(cast(void*)e);
+				newargs.shift(e);
 
 				f = cd.aggNew.overloadResolve(loc, null, newargs);
 				allocator = f.isNewDeclaration();
@@ -312,7 +312,7 @@
 				Expression e = new IntegerExp(loc, sd.size(loc), Type.tuns32);
 				if (!newargs)
 					newargs = new Expressions();
-				newargs.shift(cast(void*)e);
+				newargs.shift(e);
 
 				f = sd.aggNew.overloadResolve(loc, null, newargs);
 				allocator = f.isNewDeclaration();
@@ -353,7 +353,7 @@
 				arg = arg.optimize(WANTvalue);
 				if (arg.op == TOKint64 && cast(long)arg.toInteger() < 0)
 					error("negative array index %s", arg.toChars());
-				arguments.data[j] = cast(void*) arg;
+				arguments[j] =  arg;
 				tb = (cast(TypeDArray)tb).next.toBasetype();
 			}
 		}
@@ -389,7 +389,7 @@
 				Expression e = cast(Expression)newargs.data[i];
 
 				e = e.optimize(WANTvalue);
-				newargs.data[i] = cast(void*)e;
+				newargs[i] = e;
 			}
 		}
 
@@ -400,7 +400,7 @@
 				Expression e = cast(Expression)arguments.data[i];
 
 				e = e.optimize(WANTvalue);
-				arguments.data[i] = cast(void*)e;
+				arguments[i] = e;
 			}
 		}
 		return this;