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-980506-2.c
blob
d97c0d4f83abedc6e70957b24a7fe984a92e5cf0
1
/*
2
980506-2.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
static void
*
self
(
void
*
p
){
return
p
; }
12
13
int
14
f
()
15
{
16
struct
{
int
i
; }
s
, *
sp
;
17
int
*
ip
= &
s
.
i
;
18
19
s
.
i
=
1
;
20
sp
=
self
(&
s
);
21
22
*
ip
=
0
;
23
return
sp
->
i
+
1
;
24
}
25
26
void
27
testTortureExecute
(
void
)
28
{
29
if
(
f
() !=
1
)
30
ASSERT
(
0
);
31
else
32
return
;
33
}
34