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
Pick three bugfixes from next branch to trunk for inclusion in 4.5.0 RC2, as discusse...
[sdcc.git]
/
sdcc
/
support
/
regression
/
tests
/
gcc-torture-execute-981130-1.c
blob
140f9bb0af758fe5efffd23f258e3730ca05302b
1
/*
2
981130-1.c from the execute part of the gcc torture suite.
3
*/
4
5
#include <testfwk.h>
6
7
#ifdef __SDCC
8
#pragma std_c99
9
#endif
10
11
struct
s
{
int
a
;
int
b
;};
12
struct
s s1
;
13
struct
s s2
= {
1
,
2
, };
14
15
void
16
check
(
int
a
,
int
b
)
17
{
18
if
(
a
==
b
)
19
return
;
20
else
21
ASSERT
(
0
);
22
}
23
24
void
25
testTortureExecute
(
void
)
26
{
27
int
*
p
;
28
int
x
;
29
30
s1
.
a
=
9
;
31
p
= &
s1
.
a
;
32
s1
=
s2
;
33
x
= *
p
;
34
35
check
(
x
,
1
);
36
}
37