From: Robert R. Henry Date: Thu, 21 Aug 1980 01:04:32 +0000 (-0800) Subject: Add yywarning X-Git-Tag: BSD-4^3~857 X-Git-Url: https://git.subgeniuskitty.com/unix-history/.git/commitdiff_plain/acd69f829eb787e980cd770e037afa18220c319a Add yywarning SCCS-vsn: old/as.vax/asparse.c 4.7 --- diff --git a/usr/src/old/as.vax/asparse.c b/usr/src/old/as.vax/asparse.c index 6fff6a4b70..95ec161e94 100644 --- a/usr/src/old/as.vax/asparse.c +++ b/usr/src/old/as.vax/asparse.c @@ -1,5 +1,5 @@ /* Copyright (c) 1980 Regents of the University of California */ -static char sccsid[] = "@(#)asparse.c 4.6 %G%"; +static char sccsid[] = "@(#)asparse.c 4.7 %G%"; #include #include "as.h" #include "asexpr.h" @@ -1045,3 +1045,19 @@ yyerror(s, a1, a2,a3,a4,a5) fprintf(sink, s, a1, a2,a3,a4,a5); fprintf(sink, "\n"); } + +/*VARARGS1*/ +yywarning(s, a1, a2,a3,a4,a5) + char *s; +{ + +#define sink stdout + + if (anyerrs == 0 && ! silent) + fprintf(sink, "Assembler:\n"); + if (silent) return; + + fprintf(sink, "\"%s\", line %d: WARNING: ", dotsname, lineno); + fprintf(sink, s, a1, a2,a3,a4,a5); + fprintf(sink, "\n"); +}