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-1.c
blob
a623ff4b7d91334632fc31be372c35804aa53bfa
1
/*
2
20000717-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
// Todo: Enable when sdcc supports struct passing
12
#if 0
13
typedef
struct
trio
{
int
a
,
b
,
c
; }
trio
;
14
15
int
16
bar
(
int
i
,
trio t
)
17
{
18
if
(
t
.
a
==
t
.
b
||
t
.
a
==
t
.
c
)
19
ASSERT
(
0
);
20
}
21
22
int
23
foo
(
trio t
,
int
i
)
24
{
25
return
bar
(
i
,
t
);
26
}
27
#endif
28
29
void
30
testTortureExecute
(
void
)
31
{
32
#if 0
33
trio t
= {
1
,
2
,
3
};
34
35
foo
(
t
,
4
);
36
return
;
37
#endif
38
}
39