re PR middle-end/16558 (bogus missing-return warning)

PR middle-end/16558
	* g++.dg/warn/Wreturn-type-2.C: New test.

From-SVN: r94382
This commit is contained in:
Ian Lance Taylor 2005-01-28 17:33:54 +00:00 committed by Ian Lance Taylor
parent 09f8cf2de9
commit 6aea8136e2
2 changed files with 25 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2005-01-28 Ian Lance Taylor <ian@airs.com>
PR middle-end/16558
* g++.dg/warn/Wreturn-type-2.C: New test.
2004-06-24 Jeff Law <law@redhat.com>
* gcc.dg/tree-ssa/20050128-1.c: New test.

View File

@ -0,0 +1,20 @@
// PR middle-end/16558
// { dg-options "-Wreturn-type" }
struct C
{
C ();
~C ();
};
int getref (int ndx)
{
C d;
if (ndx != 0) {
C base;
return 0;
}
else
return 0;
}