Mercurial > projects > dstress
annotate run/c/cfloat_09_C.d @ 1322:a8cf8aa0da50
fixed malformed @uri@ entries
author | thomask |
---|---|
date | Sun, 31 Dec 2006 20:00:23 +0000 |
parents | db221d4acc19 |
children | b8c0195059d9 |
rev | line source |
---|---|
885 | 1 // $HeadURL$ |
2 // $Date$ | |
3 // $Author$ | |
4 | |
5 // @author@ Don Clugston <dac@nospam.com.au> | |
6 // @date@ 2006-03-02 | |
1322 | 7 // @uri@ news:du6chp$hub$1@digitaldaemon.com |
885 | 8 |
9 module dstress.run.c.cfloat_09_C; | |
10 | |
11 union S{ | |
12 float f; | |
13 uint i; | |
14 } | |
15 | |
16 int main(){ | |
17 float re = 0.0; | |
18 ifloat im = -0.0i; | |
19 cfloat a = re + im; | |
20 | |
21 S s; | |
22 | |
23 s.f = a.re; | |
24 if(s.i != 0x00000000){ | |
25 assert(0); | |
26 } | |
27 | |
28 s.f = a.im; | |
29 if(s.i != 0x80000000){ | |
30 assert(0); | |
31 } | |
32 | |
33 return 0; | |
34 } |