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-pr39233.c
blob
584e0d5df999eba17a5336ae4776d1d3cf62d8e8
1
/*
2
pr39233.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
#pragma disable_warning 127
10
#endif
11
12
void
13
foo
(
void
*
p
)
14
{
15
long
l
= (
long
)
p
;
16
if
(
l
<
0
||
l
>
6
)
17
ASSERT
(
0
);
18
}
19
20
void
21
testTortureExecute
(
void
)
22
{
23
short
i
;
24
for
(
i
=
6
;
i
>=
0
;
i
--)
25
#if defined(__SDCC_pic14)
// FIXME: maybe a bug in sdcc
26
foo
(
i
);
27
#else
28
foo
((
void
*) (
long
)
i
);
29
#endif
30
return
;
31
}
32