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]

Patch to sparc.h for format specifier warning


The following patch fixes this warning:

varasm.c:1884: warning: unsigned int format, different type arg (arg 4)

I assume bytes always fix in an int...

Ok to install?

		--Kaveh


2001-08-24  Kaveh R. Ghazi  <ghazi@caip.rutgers.edu>

	* sparc.h (ASM_OUTPUT_BYTE): Fix format specifier warning.

diff -rup orig/egcs-CVS20010822/gcc/config/sparc/sparc.h egcs-CVS20010822/gcc/config/sparc/sparc.h
--- orig/egcs-CVS20010822/gcc/config/sparc/sparc.h	Sat Aug 18 16:30:30 2001
+++ egcs-CVS20010822/gcc/config/sparc/sparc.h	Fri Aug 24 07:42:17 2001
@@ -3064,7 +3064,7 @@ do {									\
 /* This is how to output an assembler line for a numeric constant byte.  */
 
 #define ASM_OUTPUT_BYTE(FILE,VALUE)  \
-  fprintf (FILE, "%s0x%x\n", ASM_BYTE_OP, (VALUE))
+  fprintf (FILE, "%s0x%x\n", ASM_BYTE_OP, (int)(VALUE))
 
 /* This is how we hook in and defer the case-vector until the end of
    the function.  */


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