This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: A prototype patch for gcov-io.h


 > From: hjl@lucon.org (H.J. Lu)
 > 
 > Sat Jun 20 16:58:47 1998  H.J. Lu  (hjl@gnu.org)
 > 
 > 	* gcov-io.h (__fetch_long): New declaration.
 > 	(__store_long): Likewise.
 > 	(__read_long): Likewise.
 > 	(__write_long): Likewise.
 > 
 > Index: gcov-io.h
 > ===================================================================
 > RCS file: /home/work/cvs/gnu/egcs/gcc/gcov-io.h,v
 > retrieving revision 1.1.1.3
 > diff -u -p -r1.1.1.3 gcov-io.h
 > --- gcov-io.h	1998/01/14 03:09:57	1.1.1.3
 > +++ gcov-io.h	1998/06/21 00:13:13
 > @@ -24,6 +24,11 @@ Boston, MA 02111-1307, USA.  */
 >  #include <stdio.h>
 >  #include <sys/types.h>
 >  
 > +static int __fetch_long		PROTO((long *, char *, int));
 > +static int __store_long		PROTO((long, char *, size_t));
 > +static int __read_long		PROTO((long *, FILE *, size_t));
 > +static int __write_long		PROTO((long, FILE *, size_t));
 > +

	BTW, __fetch_long should probably be rewritten to take a size_t
as its last argument to be consistent with the other three functions.  I
took a look, but its a little hairy to do it right and still clean all
sign/unsigned comparison warnings.  Any takers?

	Also, IMHO gcov-io.h shouldn't include stdio.h or types.h which
I see peeking above your patch additions. 

		--Kaveh

PS: Great to see these, keep 'em coming!
--
Kaveh R. Ghazi			Project Manager / Custom Development
ghazi@caip.rutgers.edu		Icon CMT Corp.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]