repo.or.cz
/
sdcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
struct / union in initializer, RFE #901.
[sdcc.git]
/
sdcc
/
support
/
regression
/
tests
/
gcc-torture-execute-20000511-1.c
blob
b02ef8d8f6dce02c1fdc2e46077a9883b15e04eb
1
/*
2
20000511-1.c from the execute part of the gcc torture tests.
3
*/
4
5
#include <testfwk.h>
6
7
#ifdef __SDCC
8
#pragma std_c99
9
#endif
10
11
void
f
(
int
value
,
int
expect
)
12
{
13
if
(
value
!=
expect
)
14
ASSERT
(
0
);
15
}
16
17
void
18
testTortureExecute
(
void
)
19
{
20
int
a
=
7
,
b
=
6
,
c
=
4
,
d
=
7
,
e
=
2
;
21
22
f
(
a
||
b
%
c
,
1
);
23
f
(
a
?
b
%
c
:
0
,
2
);
24
f
(
a
=
b
%
c
,
2
);
25
f
(
a
*=
b
%
c
,
4
);
26
f
(
a
/=
b
%
c
,
2
);
27
f
(
a
%=
b
%
c
,
0
);
28
f
(
a
+=
b
%
c
,
2
);
29
f
(
d
||
c
&&
e
,
1
);
30
f
(
d
?
c
&&
e
:
0
,
1
);
31
f
(
d
=
c
&&
e
,
1
);
32
f
(
d
*=
c
&&
e
,
1
);
33
f
(
d
%=
c
&&
e
,
0
);
34
f
(
d
+=
c
&&
e
,
1
);
35
f
(
d
-=
c
&&
e
,
0
);
36
f
(
d
||
c
||
e
,
1
);
37
f
(
d
?
c
||
e
:
0
,
0
);
38
f
(
d
=
c
||
e
,
1
);
39
f
(
d
*=
c
||
e
,
1
);
40
f
(
d
%=
c
||
e
,
0
);
41
f
(
d
+=
c
||
e
,
1
);
42
f
(
d
-=
c
||
e
,
0
);
43
return
;
44
}
45