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: warning fix take two



This is the text suggested by Geert Bosch.  The current warning is
confusing at best.   Ok to commit?

2001-02-10  Anthony Green  <green@redhat.com>

	* c-common.c (combine_strings): Improve warning message.


Index: gcc/c-common.c
===================================================================
RCS file: /cvs/gcc/gcc/gcc/c-common.c,v
retrieving revision 1.224
diff -c -r1.224 c-common.c
*** c-common.c	2001/01/28 01:50:04	1.224
--- c-common.c	2001/02/10 14:49:53
***************
*** 466,472 ****
    nchars = wide_flag ? length / wchar_bytes : length;
  
    if (pedantic && nchars - 1 > nchars_max && c_language == clk_c)
!     pedwarn ("string length `%d' is greater than the minimum length `%d' ISO C%d is required to support",
  	     nchars - 1, nchars_max, flag_isoc99 ? 99 : 89);
  
    /* Create the array type for the string constant.
--- 466,472 ----
    nchars = wide_flag ? length / wchar_bytes : length;
  
    if (pedantic && nchars - 1 > nchars_max && c_language == clk_c)
!     pedwarn ("string length `%d' is greater than the length `%d' ISO C%d compilers are required to support",
  	     nchars - 1, nchars_max, flag_isoc99 ? 99 : 89);
  
    /* Create the array type for the string constant.


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