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
/
bug-2274.c
blob
d061992d9a8b7964506537232dd00929e94909ef
1
/*
2
bug-2274.c
3
*/
4
5
#include <testfwk.h>
6
7
#pragma disable_warning 84
8
9
char
func_0
(
int
i
)
10
{
11
return
i
+
10
;
12
}
13
14
char
func_1
(
char
i
)
15
{
16
return
i
+
20
;
17
}
18
19
int
func_2
(
int
i
)
20
{
21
return
i
+
30
;
22
}
23
24
int
func_3
(
char
i
)
25
{
26
return
i
+
40
;
27
}
28
29
void
uninitialized
(
void
)
__reentrant
30
{
31
/* SDCC should not crash, but only print warning messages. */
32
char
a
=
func_0
(
a
);
33
char
b
=
func_1
(
b
);
34
int
c
=
func_2
(
c
);
35
int
d
=
func_3
(
d
);
36
}
37
38
void
testBug
(
void
)
39
{
40
uninitialized
();
41
}