Mercurial > projects > dstress
view run/o/opDiv_09_A.d @ 522:7466721ce7d1
opDiv run time versus compile time
David Friedman <d3rdclsmail_a_@_t_earthlink_d_._t_net>
2005-05-03
news:d595il$lqr$2@digitaldaemon.com
author | thomask |
---|---|
date | Wed, 11 May 2005 17:11:23 +0000 |
parents | |
children | b8c0195059d9 |
line wrap: on
line source
// $HeadURL$ // $Date$ // $Author$ // @author@ David Friedman <d3rdclsmail_a_@_t_earthlink_d_._t_net> // @date@ 2005-05-03 // @uri@ news:d595il$lqr$2@digitaldaemon.com module dstress.run.o.opDiv_09_A; int main(){ real a = -1.0L / 0.0L; real b = -1.0L; real c = 0.0L; real d; byte* X = cast(byte*) (cast(void*) &a); d = b/c; byte* Y = cast(byte*) (cast(void*) &d); for(int i=0; i<a.sizeof; i++){ assert(X[i]==Y[i]); } return 0; }