This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Patch installed to fixfixes.c to avoid ANSI string concatenation
- To: bkorb at gnu dot org
- Subject: Patch installed to fixfixes.c to avoid ANSI string concatenation
- From: "Kaveh R. Ghazi" <ghazi at caip dot rutgers dot edu>
- Date: Sun, 16 Jul 2000 13:24:17 -0400 (EDT)
- Cc: gcc-patches at gcc dot gnu dot org
I installed the following patch to allow fixfixes.c to be compiled
with sunos4's K&R cc. Tested by compiling/running fixincludes on
sunos4 and diff'ing the fixed headers.
--Kaveh
2000-07-16 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
* fixinc/fixfixes.c (emit_gnu_type): Avoid string concatenation.
diff -rup ../egcs-CVS20000716/gcc/fixinc/fixfixes.c egcs-CVS20000716/gcc/fixinc/fixfixes.c
--- ../egcs-CVS20000716/gcc/fixinc/fixfixes.c Thu Jul 13 12:12:23 2000
+++ egcs-CVS20000716/gcc/fixinc/fixfixes.c Sun Jul 16 13:10:51 2000
@@ -164,15 +164,17 @@ emit_gnu_type ( text, rm )
/*
* Now print out the reformed typedef
*/
- printf ("#ifndef __%s_TYPE__\n"
- "#define __%s_TYPE__ %s\n"
- "#endif\n",
+ printf ("\
+#ifndef __%s_TYPE__\n\
+#define __%s_TYPE__ %s\n\
+#endif\n",
p_tm->pz_TYPE, p_tm->pz_TYPE, p_tm->pz_gtype );
- printf ("#if !defined(_GCC_%s_T)%s\n"
- "#define _GCC_%s_T\n"
- "typedef __%s_TYPE__ %s_t;\n"
- "#endif\n",
+ printf ("\
+#if !defined(_GCC_%s_T)%s\n\
+#define _GCC_%s_T\n\
+typedef __%s_TYPE__ %s_t;\n\
+#endif\n",
p_tm->pz_TYPE, p_tm->pz_cxx_guard,
p_tm->pz_TYPE, p_tm->pz_TYPE, p_tm->pz_type);