]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
decl.c (finish_function): Give a pedwarn for reaching end of non-void function, not...
authorBrendan Kehoe <brendan@cygnus.com>
Tue, 24 Feb 1998 08:37:13 +0000 (08:37 +0000)
committerBrendan Kehoe <brendan@gcc.gnu.org>
Tue, 24 Feb 1998 08:37:13 +0000 (03:37 -0500)
        * decl.c (finish_function): Give a pedwarn for reaching end of
        non-void function, not just a warning.

From-SVN: r18217

gcc/cp/ChangeLog
gcc/cp/decl.c

index 757a1fd238944ed8c315c85a47a4ad21e7d125b5..e10f4d7bb447e3ffcdf950c0ed3e32e4c956233b 100644 (file)
@@ -1,3 +1,8 @@
+1998-02-24  Brendan Kehoe  <brendan@cygnus.com>
+
+       * decl.c (finish_function): Give a pedwarn for reaching end of
+       non-void function, not just a warning.
+
 Tue Feb 24 01:40:24 1998  Jason Merrill  <jason@yorick.cygnus.com>
 
        * pt.c (instantiate_class_template): Don't instantiate if pedantic
index df260a304cdb22f42f049ac90d5c72687c8d7f4d..f5f33970dbe687badb444ac239d195ca1d969da3 100644 (file)
@@ -12552,7 +12552,7 @@ finish_function (lineno, call_poplevel, nested)
        {
          /* If this function returns non-void and control can drop through,
             complain.  */
-         cp_warning ("control reaches end of non-void function `%D'", fndecl);
+         cp_pedwarn ("control reaches end of non-void function `%D'", fndecl);
        }
       /* With just -W, complain only if function returns both with
         and without a value.  */