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-20000717-3.c
blob
56c0b63254fc2c605fb52d994a048616f2e80f21
1
/*
2
20000717-3.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
int
c
= -
1
;
12
13
int
14
foo
(
int
*
p
)
15
{
16
int
x
;
17
int
a
;
18
19
a
=
p
[
0
];
20
x
=
a
+
5
;
21
a
=
c
;
22
p
[
0
] =
x
-
15
;
23
return
a
;
24
}
25
26
void
27
testTortureExecute
(
void
)
28
{
29
int
b
=
1
;
30
int
a
=
foo
(&
b
);
31
32
ASSERT
(!(
a
!= -
1
||
b
!= (
1
+
5
-
15
)));
33
34
return
;
35
}
36