OSDN Git Service
(root)
/
pf3gnuchains
/
gcc-fork.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
history
|
raw
|
HEAD
PR middle-end/35456
[pf3gnuchains/gcc-fork.git]
/
gcc
/
testsuite
/
gcc.c-torture
/
execute
/
pr30185.c
1
/* PR target/30185 */
2
3
extern void abort (void);
4
5
typedef struct S { char a; long long b; } S;
6
7
S
8
foo (S x, S y)
9
{
10
S z;
11
z.b = x.b / y.b;
12
return z;
13
}
14
15
int
16
main (void)
17
{
18
S a, b;
19
a.b = 32LL;
20
b.b = 4LL;
21
if (foo (a, b).b != 8LL)
22
abort ();
23
a.b = -8LL;
24
b.b = -2LL;
25
if (foo (a, b).b != 4LL)
26
abort ();
27
return 0;
28
}