From 3d05a5de82e9119ec0783801456a2ba5f5493ba1 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Wed, 18 Jun 1997 17:09:27 +0000 Subject: [PATCH] (fatal, warn, berror): Make error messages standard. (toomany): Improve error message text. --- src/main.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main.c b/src/main.c index 3ef6683e..0b6e2464 100644 --- a/src/main.c +++ b/src/main.c @@ -135,9 +135,9 @@ fatal(s) extern char *infile; if (infile == 0) - fprintf(stderr, _("fatal error: %s\n"), s); + fprintf(stderr, _("bison: fatal error: %s\n"), s); else - fprintf(stderr, _("\"%s\", line %d: %s\n"), infile, lineno, s); + fprintf(stderr, _("%s:%d: fatal error: %s\n"), infile, lineno, s); done(1); } @@ -163,9 +163,9 @@ warn(s) extern char *infile; if (infile == 0) - fprintf(stderr, _("error: %s\n"), s); + fprintf(stderr, _("bison: %s\n"), s); else - fprintf(stderr, _("(\"%s\", line %d) error: %s\n"), + fprintf(stderr, _("%s:%d: %s\n"), infile, lineno, s); failure = 1; @@ -228,7 +228,7 @@ toomany(s) char *s; { char buffer[200]; - sprintf(buffer, _("limit of %d exceeded, too many %s"), MAXSHORT, s); + sprintf(buffer, _("too many %s (max %d)"), s, MAXSHORT); fatal(buffer); } @@ -238,6 +238,6 @@ void berror(s) char *s; { - fprintf(stderr, _("internal error, %s\n"), s); + fprintf(stderr, _("bison: internal error: %s\n"), s); abort(); } -- 2.47.2