blob: 5183e63222881de2be99b009c8db25bfe22fe7ac (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
|
/* { dg-do run } */
/* { dg-options "-flto -fipa-type-escape-analysis -fdump-ipa-type-escape-analysis" } */
#include <assert.h>
int
main ()
{
struct astruct_s
{
_Bool a;
_Bool c;
_Bool b;
};
struct astruct_s b[2];
_Bool *first_of_second = &(b[1].a);
_Bool *c_0 = &(b[0].c);
_Bool *a_1 = &(b[1].a);
_Bool *a_1_from_c_0 = c_0 + 1;
_Bool test = a_1_from_c_0 == a_1;
char compile_test[test ? 1 : -1];
assert (test);
}
|