Mercurial > hg > CbC > CbC_gcc
comparison gcc/testsuite/g++.dg/other/pr89692.C @ 145:1830386684a0
gcc-9.2.0
author | anatofuz |
---|---|
date | Thu, 13 Feb 2020 11:34:05 +0900 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
131:84e7813d76e9 | 145:1830386684a0 |
---|---|
1 // PR lto/89692 | |
2 // { dg-do compile } | |
3 // { dg-require-effective-target lto } | |
4 // { dg-options "-flto -O2" } | |
5 | |
6 struct S { | |
7 short int a, b; | |
8 unsigned char c : 1; | |
9 }; | |
10 | |
11 bool | |
12 foo (void) | |
13 { | |
14 unsigned char d[sizeof (S)] = { 0 }; | |
15 S e; | |
16 | |
17 __builtin_memcpy (&e, d, sizeof (d)); | |
18 | |
19 return e.c == d[0]; | |
20 } |