From bc4c651ed9fc6908554c33d7f3b445a81da83ffb Mon Sep 17 00:00:00 2001 From: marxin Date: Mon, 7 Dec 2015 15:35:25 +0000 Subject: [PATCH] Fix changelog entry and add pr66896.C. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@231365 138bc75d-0d04-0410-961f-82ee72b054a4 --- gcc/testsuite/ChangeLog | 8 ++++---- gcc/testsuite/g++.dg/ipa/pr66896.C | 22 ++++++++++++++++++++++ 2 files changed, 26 insertions(+), 4 deletions(-) create mode 100644 gcc/testsuite/g++.dg/ipa/pr66896.C diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index a937bb3b118..46b79e057fb 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2015-12-07 Martin Liska + + * g++.dg/ipa/pr66896.C: New test. + 2015-12-06 Dmitry Vyukov * gcc.dg/sancov/sancov.exp: Load asan-dg.exp. @@ -10830,10 +10834,6 @@ PR rtl-optimization/66626 * gcc.target/i386/pr66626-2.c: New. -2015-07-16 Martin Liska - - * g++.dg/ipa/pr66896.c: New test. - 2015-07-16 Richard Biener PR tree-optimization/66894 diff --git a/gcc/testsuite/g++.dg/ipa/pr66896.C b/gcc/testsuite/g++.dg/ipa/pr66896.C new file mode 100644 index 00000000000..236537a5ea0 --- /dev/null +++ b/gcc/testsuite/g++.dg/ipa/pr66896.C @@ -0,0 +1,22 @@ +// PR ipa/66896 +// { dg-do compile } + +void f2 (void *); +void f3 (); + +struct A +{ + int *a; + A (); + ~A () { a3 (); } + int a1 (int * p) { if (!p) f3 (); f2 (p); } + void a3 () { if (*a) a1 (a); } +}; + +struct B : A {~B () { a3 ();}}; + +struct F {}; + +struct G : F {B g;}; + +void foo () {G g;} -- 2.11.4.GIT