parse.y: Use VA_OPEN/VA_CLOSE/VA_FIXEDARG throughout.

* parse.y: Use VA_OPEN/VA_CLOSE/VA_FIXEDARG throughout.
	* jv-scan.c: Likewise.

From-SVN: r45671
This commit is contained in:
Andreas Jaeger 2001-09-18 07:22:40 +02:00
parent 5dead3e5cd
commit e64c46ce50
3 changed files with 1430 additions and 1457 deletions

File diff suppressed because it is too large Load Diff

View File

@ -239,42 +239,26 @@ DEFUN (main, (argc, argv),
void
fatal_error VPARAMS ((const char *s, ...))
{
#ifndef ANSI_PROTOTYPES
const char *s;
#endif
va_list ap;
VA_START (ap, s);
#ifndef ANSI_PROTOTYPES
s = va_arg (ap, const char *);
#endif
VA_OPEN (ap, s);
VA_FIXEDARG (ap, const char *, s);
fprintf (stderr, "%s: error: ", exec_name);
vfprintf (stderr, s, ap);
fputc ('\n', stderr);
va_end (ap);
VA_CLOSE (ap);
exit (1);
}
void
warning VPARAMS ((const char *s, ...))
{
#ifndef ANSI_PROTOTYPES
const char *s;
#endif
va_list ap;
VA_START (ap, s);
#ifndef ANSI_PROTOTYPES
s = va_arg (ap, const char *);
#endif
VA_OPEN (ap, s);
VA_FIXEDARG (ap, const char *, s);
fprintf (stderr, "%s: warning: ", exec_name);
vfprintf (stderr, s, ap);
fputc ('\n', stderr);
va_end (ap);
VA_CLOSE (ap);
}
void

View File

@ -3085,19 +3085,11 @@ issue_warning_error_from_context (cl, msg, ap)
void
parse_error_context VPARAMS ((tree cl, const char *msg, ...))
{
#ifndef ANSI_PROTOTYPES
tree cl;
const char *msg;
#endif
va_list ap;
VA_START (ap, msg);
#ifndef ANSI_PROTOTYPES
cl = va_arg (ap, tree);
msg = va_arg (ap, const char *);
#endif
VA_OPEN (ap, msg);
VA_FIXEDARG (ap, tree, cl);
VA_FIXEDARG (ap, const char *, msg);
issue_warning_error_from_context (cl, msg, ap);
va_end (ap);
VA_CLOSE (ap);
}
/* Issue a warning at a current source line CL */
@ -3105,22 +3097,14 @@ parse_error_context VPARAMS ((tree cl, const char *msg, ...))
static void
parse_warning_context VPARAMS ((tree cl, const char *msg, ...))
{
#ifndef ANSI_PROTOTYPES
tree cl;
const char *msg;
#endif
va_list ap;
VA_START (ap, msg);
#ifndef ANSI_PROTOTYPES
cl = va_arg (ap, tree);
msg = va_arg (ap, const char *);
#endif
VA_OPEN (ap, msg);
VA_FIXEDARG (ap, tree, cl);
VA_FIXEDARG (ap, const char *, msg);
force_error = do_warning = 1;
issue_warning_error_from_context (cl, msg, ap);
do_warning = force_error = 0;
va_end (ap);
VA_CLOSE (ap);
}
static tree