This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Patch: fix-header.c, also fix prototypes for functions taking "void".
- To: egcs-patches at egcs dot cygnus dot com
- Subject: Patch: fix-header.c, also fix prototypes for functions taking "void".
- From: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- Date: Fri, 4 Feb 2000 23:20:48 -0500 (EST)
Regarding:
http://gcc.gnu.org/ml/gcc-bugs/2000-02/msg00070.html
I'm guessing that fix-header skips void arg functions simply because
C++ doesn't strictly need it.
OTOH, I see no reason why prototyping these would hurt. So...
Okay to install?
--Kaveh
2000-02-04 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* fix-header.c (recognized_function): Also fix prototypes for
functions taking "void".
diff -rup orig/egcs-CVS20000204/gcc/fix-header.c egcs-CVS20000204/gcc/fix-header.c
--- orig/egcs-CVS20000204/gcc/fix-header.c Fri Jan 14 12:05:22 2000
+++ egcs-CVS20000204/gcc/fix-header.c Fri Feb 4 16:28:20 2000
@@ -569,7 +569,7 @@ recognized_function (fname, fname_length
if (fn == NULL)
return;
- if (fn->params[0] == '\0' || strcmp (fn->params, "void") == 0)
+ if (fn->params[0] == '\0')
return;
/* We only have a partial function declaration,