repo.or.cz
/
official-gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git]
/
gcc
/
testsuite
/
gcc.c-torture
/
execute
/
ieee
/
minuszero.c
blob
85715261d6196955b37296febc85fcfbc132084c
1
main
()
2
{
3
union
4
{
5
double
d
;
6
unsigned short
i
[
sizeof
(
double
) /
sizeof
(
short
)];
7
}
u
;
8
int
a
=
0
;
9
int
b
= -
5
;
10
int
j
;
11
12
u
.
d
= (
double
)
a
/
b
;
13
14
/* Look for the right pattern, but be sloppy since
15
we don't know the byte order. */
16
for
(
j
=
0
;
j
<
sizeof
(
double
) /
sizeof
(
short
);
j
++)
17
{
18
if
(
u
.
i
[
j
] ==
0x8000
)
19
exit
(
0
);
20
}
21
abort
();
22
}