Mercurial > projects > dstress
view run/c/continue_04_B.d @ 1630:d0efa3ae5522 default tip
run/mini/naked_asm5: New x86_64 ABI passes the arguments in reverse order.
author | David Nadlinger <code@klickverbot.at> |
---|---|
date | Sat, 23 Apr 2011 22:57:32 +0200 |
parents | 20d8ee6523e1 |
children |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ // @author@ Chris Miller <chris@dprogramming.com> // @date@ 2006-02-16 // @uri@ http://www.digitalmars.com/pnews/read.php?server=news.digitalmars.com&group=digitalmars.D.bugs&artnum=6288 module dstress.run.c.continue_04_B; struct MyStruct{ int opApply(int delegate(ref int i) dg){ for(int index=0; index < 3; index++){ dg(index); } return 0; } } int main(){ MyStruct foo; int sum; label: foreach(int i; foo){ sum += i; continue label; } if(sum == 3){ return 0; } }