116 |
|
|
117 |
void |
void |
118 |
#if defined VA_START && defined __STDC__ |
#if defined VA_START && defined __STDC__ |
119 |
warn_at (int location, const char *message, ...) |
warn_at (location_t location, const char *message, ...) |
120 |
#else |
#else |
121 |
warn_at (location, message, va_alist) |
warn_at (location, message, va_alist) |
122 |
int location |
location_t location |
123 |
char *message; |
char *message; |
124 |
va_dcl |
va_dcl |
125 |
#endif |
#endif |
133 |
static const char *old_infile; |
static const char *old_infile; |
134 |
static int old_lineno; |
static int old_lineno; |
135 |
|
|
136 |
if (old_lineno == location && |
if (old_lineno == location.first_line && |
137 |
(infile == old_infile || !strcmp (old_infile, infile))) |
(infile == old_infile || !strcmp (old_infile, infile))) |
138 |
/* Simply return and print nothing. */ |
/* Simply return and print nothing. */ |
139 |
return; |
return; |
140 |
|
|
141 |
old_infile = infile; |
old_infile = infile; |
142 |
old_lineno = location; |
old_lineno = location.first_line; |
143 |
} |
} |
144 |
|
|
145 |
fflush (stdout); |
fflush (stdout); |
146 |
if (infile != NULL) |
LOCATION_PRINT (stderr, location); |
147 |
fprintf (stderr, "%s:%d: ", infile, location); |
fputs (": ", stderr); |
|
else |
|
|
fprintf (stderr, "%s:", program_name); |
|
|
|
|
148 |
fputs (_("warning: "), stderr); |
fputs (_("warning: "), stderr); |
149 |
|
|
150 |
#ifdef VA_START |
#ifdef VA_START |
215 |
|
|
216 |
void |
void |
217 |
#if defined VA_START && defined __STDC__ |
#if defined VA_START && defined __STDC__ |
218 |
complain_at (int location, const char *message, ...) |
complain_at (location_t location, const char *message, ...) |
219 |
#else |
#else |
220 |
complain_at (location, message, va_alist) |
complain_at (location, message, va_alist) |
221 |
int location; |
location_t location; |
222 |
char *message; |
char *message; |
223 |
va_dcl |
va_dcl |
224 |
#endif |
#endif |
232 |
static const char *old_infile; |
static const char *old_infile; |
233 |
static int old_lineno; |
static int old_lineno; |
234 |
|
|
235 |
if (old_lineno == location && |
if (old_lineno == location.first_line && |
236 |
(infile == old_infile || !strcmp (old_infile, infile))) |
(infile == old_infile || !strcmp (old_infile, infile))) |
237 |
/* Simply return and print nothing. */ |
/* Simply return and print nothing. */ |
238 |
return; |
return; |
239 |
|
|
240 |
old_infile = infile; |
old_infile = infile; |
241 |
old_lineno = location; |
old_lineno = location.first_line; |
242 |
} |
} |
243 |
|
|
244 |
fflush (stdout); |
fflush (stdout); |
245 |
if (infile != NULL) |
LOCATION_PRINT (stderr, location); |
246 |
fprintf (stderr, "%s:%d: ", infile, location); |
fputs (": ", stderr); |
|
else |
|
|
fprintf (stderr, "%s:", program_name); |
|
247 |
|
|
248 |
#ifdef VA_START |
#ifdef VA_START |
249 |
VA_START (args, message); |
VA_START (args, message); |
311 |
|
|
312 |
void |
void |
313 |
#if defined VA_START && defined __STDC__ |
#if defined VA_START && defined __STDC__ |
314 |
fatal_at (int location, const char *message, ...) |
fatal_at (location_t location, const char *message, ...) |
315 |
#else |
#else |
316 |
fatal (location, message, va_alist) |
fatal (location, message, va_alist) |
317 |
int location; |
location_t location; |
318 |
char *message; |
char *message; |
319 |
va_dcl |
va_dcl |
320 |
#endif |
#endif |
324 |
#endif |
#endif |
325 |
|
|
326 |
fflush (stdout); |
fflush (stdout); |
327 |
if (infile != NULL) |
LOCATION_PRINT (stderr, location); |
328 |
fprintf (stderr, "%s:%d: ", infile, location); |
fputs (": ", stderr); |
|
else |
|
|
fprintf (stderr, "%s:", program_name); |
|
|
|
|
329 |
fputs (_("fatal error: "), stderr); |
fputs (_("fatal error: "), stderr); |
330 |
|
|
331 |
#ifdef VA_START |
#ifdef VA_START |