repo.or.cz
/
gcc.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
Daily bump.
[gcc.git]
/
gcc
/
testsuite
/
g++.dg
/
warn
/
Warray-bounds-14.C
blob
0812f833d748e9befb273b4b412838351df818f5
1
/* PR middle-end/97595 - bogus -Wstringop-overflow due to DECL_SIZE_UNIT
2
underreporting field size
3
{ dg-do compile }
4
{ dg-options "-O2 -Wall" } */
5
6
struct A { char a[32]; };
7
struct B: virtual A { };
8
struct C: B { };
9
10
struct D
11
{
12
B &b;
13
D (B&);
14
};
15
16
D::D (B &b): b (b) { } // { dg-bogus "-Warray-bounds" }
17
18
void f (void*);
19
20
void g ()
21
{
22
C c;
23
D d (c);
24
f (&d);
25
}