Mercurial > projects > dstress
view run/t/template_32_I.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 | 902d2c168029 |
children |
line wrap: on
line source
// $HeadUR$ // $Date$ // $Author$ // @author@ Dave <Dave_member@pathlink.com> // @date@ 2006-03-18 // @uri@ news:dvgq34$22hv$1@digitaldaemon.com // @uri@ http://d.puremagic.com/issues/show_bug.cgi?id=487 module dstress.run.t.template_32_I; template sum(float x){ static if (x <= 1.0f){ const float sum = x; }else{ const float sum = x + sum!(x - 1.0f); } } int main(){ float x = sum!(1.0f); if(x != 1.0f){ assert(0); } return 0; }