Mercurial > projects > dstress
view run/f/for_06_F.d @ 1472:22767ec83a24
[Issue 932] static foreach in second template instantiation uses wrong tupleof
Frits van Bommel <fvbommel@wxs.nl>
2007-02-06
http://d.puremagic.com/issues/show_bug.cgi?id=932
author | thomask |
---|---|
date | Thu, 05 Apr 2007 16:36:53 +0000 |
parents | 9dcac8d4e97f |
children | b8c0195059d9 |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ // @author@ Deewiant <deewiant.doesnotlike.spam@gmail.com> // @date@ 2005-08-06 // @uri@ news:dd23j9$1b6c$1@digitaldaemon.com module dstress.run.f.for_06_F; int foo(inout real[] arr) { size_t i = 1; int counter; for(size_t j = arr.length-1; j >= i; j--) { size_t dummy = j; arr[j] = arr[j - i]; counter++; } return counter; } int main(){ real[] array; array.length = 2; if(foo(array)==1){ return 0; }else{ return 1; } }