From: mpolacek Date: Fri, 11 Oct 2019 20:53:26 +0000 (+0000) Subject: PR c++/92070 - bogus error with -fchecking=2. X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=707aa069296cd42f27d1b53b38205b163c64af3f;p=thirdparty%2Fgcc.git PR c++/92070 - bogus error with -fchecking=2. * g++.dg/expr/cond17.C: New test. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@276907 138bc75d-0d04-0410-961f-82ee72b054a4 --- diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index bbcea404db49..dadb4425cc91 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,8 @@ +2019-10-11 Marek Polacek + + PR c++/92070 - bogus error with -fchecking=2. + * g++.dg/expr/cond17.C: New test. + 2019-10-11 Marek Polacek PR c++/92049 - extra error with -fchecking=2. diff --git a/gcc/testsuite/g++.dg/expr/cond17.C b/gcc/testsuite/g++.dg/expr/cond17.C new file mode 100644 index 000000000000..1999c376dd15 --- /dev/null +++ b/gcc/testsuite/g++.dg/expr/cond17.C @@ -0,0 +1,11 @@ +// PR c++/92070 - bogus error with -fchecking=2. +// { dg-additional-options "-fchecking=2" } + +struct a; +struct b { + static a c(); +}; +struct a : b {}; +template struct d { + void e() { 0 ? b() : b::c(); } +};