Mercurial > projects > dstress
view run/d/double_27_C.d @ 1576:b3e16c86558e
[Issue 1398] New: GDC doesn't generate correct code
<mariusmuja@gmail.com>
2007-08-04
http://d.puremagic.com/issues/show_bug.cgi?id=1398
author | thomask |
---|---|
date | Thu, 21 Feb 2008 15:20:08 +0000 |
parents | 23fe17e22a63 |
children |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ // based on: gcc.c-torture/execute/ieee/acc1.c module dstress.run.d.double_27_C; double func (double *array){ double d = *array; if (d == 0.0){ return d; }else{ return d + func (array + 1); } } int main (){ const double values[] = [0.1e-100, 1.0, -1.0, 0.0]; if(func(values.ptr) != 0.1e-100){ assert(0); } return 0; }