comparison gcc/errors.c @ 55:77e2b8dfacca gcc-4.4.5

update it from 4.4.3 to 4.5.0
author ryoma <e075725@ie.u-ryukyu.ac.jp>
date Fri, 12 Feb 2010 23:39:51 +0900
parents a06113de4d67
children 04ced10e8804
comparison
equal deleted inserted replaced
52:c156f1bd5cd9 55:77e2b8dfacca
38 38
39 int have_error = 0; 39 int have_error = 0;
40 40
41 /* Print a warning message - output produced, but there may be problems. */ 41 /* Print a warning message - output produced, but there may be problems. */
42 42
43 bool 43 void
44 warning (int opt ATTRIBUTE_UNUSED, const char *format, ...) 44 warning (const char *format, ...)
45 { 45 {
46 va_list ap; 46 va_list ap;
47 47
48 va_start (ap, format); 48 va_start (ap, format);
49 fprintf (stderr, "%s: warning: ", progname); 49 fprintf (stderr, "%s: warning: ", progname);
50 vfprintf (stderr, format, ap); 50 vfprintf (stderr, format, ap);
51 va_end (ap); 51 va_end (ap);
52 fputc('\n', stderr); 52 fputc('\n', stderr);
53 return true;
54 } 53 }
55 54
56 55
57 /* Print an error message - we keep going but the output is unusable. */ 56 /* Print an error message - we keep going but the output is unusable. */
58 57
103 102
104 /* Given a partial pathname as input, return another pathname that 103 /* Given a partial pathname as input, return another pathname that
105 shares no directory elements with the pathname of __FILE__. This 104 shares no directory elements with the pathname of __FILE__. This
106 is used by fancy_abort() to print `Internal compiler error in expr.c' 105 is used by fancy_abort() to print `Internal compiler error in expr.c'
107 instead of `Internal compiler error in ../../GCC/gcc/expr.c'. This 106 instead of `Internal compiler error in ../../GCC/gcc/expr.c'. This
108 version if for the gen* programs and so needn't handle subdirectories. */ 107 version is meant to be used for the gen* programs and therefor need not
108 handle subdirectories. */
109 109
110 const char * 110 const char *
111 trim_filename (const char *name) 111 trim_filename (const char *name)
112 { 112 {
113 static const char this_file[] = __FILE__; 113 static const char this_file[] = __FILE__;