Mercurial > projects > ddmd
comparison dmd/CastExp.d @ 12:832f71e6f96c
*Exp and *AssignExp arrayOp implementation added (might be a bit incomplete)
Some unittest-specific functions implemented
author | korDen |
---|---|
date | Mon, 12 Apr 2010 15:13:00 +0400 |
parents | 10317f0c89a5 |
children | a8b50ff7f201 |
comparison
equal
deleted
inserted
replaced
11:3356c90e9aac | 12:832f71e6f96c |
---|---|
376 expToCBuffer(buf, hgs, e1, precedence[op]); | 376 expToCBuffer(buf, hgs, e1, precedence[op]); |
377 } | 377 } |
378 | 378 |
379 void buildArrayIdent(OutBuffer buf, Expressions arguments) | 379 void buildArrayIdent(OutBuffer buf, Expressions arguments) |
380 { | 380 { |
381 assert(false); | 381 Type tb = type.toBasetype(); |
382 if (tb.ty == Tarray || tb.ty == Tsarray) | |
383 { | |
384 e1.buildArrayIdent(buf, arguments); | |
385 } | |
386 else | |
387 Expression.buildArrayIdent(buf, arguments); | |
382 } | 388 } |
383 | 389 |
384 Expression buildArrayLoop(Arguments fparams) | 390 Expression buildArrayLoop(Arguments fparams) |
385 { | 391 { |
386 assert(false); | 392 Type tb = type.toBasetype(); |
393 if (tb.ty == Tarray || tb.ty == Tsarray) | |
394 { | |
395 return e1.buildArrayLoop(fparams); | |
396 } | |
397 else | |
398 return Expression.buildArrayLoop(fparams); | |
387 } | 399 } |
388 | 400 |
389 static int X(int fty, int tty) { | 401 static int X(int fty, int tty) { |
390 return ((fty) * TY.TMAX + (tty)); | 402 return ((fty) * TY.TMAX + (tty)); |
391 } | 403 } |