aboutsummaryrefslogtreecommitdiff
path: root/gdb/m2-exp.y
diff options
context:
space:
mode:
authorStan Shebs <shebs@codesourcery.com>1994-05-12 03:21:48 +0000
committerStan Shebs <shebs@codesourcery.com>1994-05-12 03:21:48 +0000
commit8db1a922914c22a21875e5238377dda17d34c21a (patch)
tree6a6f4d16f73953a9b94afbe01e2024bda36ec0ce /gdb/m2-exp.y
parent7e16be786a221bf773e7911351a0352fb3a04d80 (diff)
downloadgdb-8db1a922914c22a21875e5238377dda17d34c21a.zip
gdb-8db1a922914c22a21875e5238377dda17d34c21a.tar.gz
gdb-8db1a922914c22a21875e5238377dda17d34c21a.tar.bz2
Wed May 11 20:11:51 1994 Stan Shebs (shebs@andros.cygnus.com)
* c-exp.y (yyerror): Display a more informative error message. * ch-exp.y (yyerror): Ditto, don't use global yychar. * m2-exp.y (yyerror): Ditto.
Diffstat (limited to 'gdb/m2-exp.y')
-rw-r--r--gdb/m2-exp.y11
1 files changed, 3 insertions, 8 deletions
diff --git a/gdb/m2-exp.y b/gdb/m2-exp.y
index 0b8961d..bbbdda4 100644
--- a/gdb/m2-exp.y
+++ b/gdb/m2-exp.y
@@ -1152,13 +1152,8 @@ make_qualname(mod,ident)
#endif /* 0 */
void
-yyerror(msg)
- char *msg; /* unused */
+yyerror (msg)
+ char *msg;
{
- printf_unfiltered("Parsing: %s\n",lexptr);
- if (yychar < 256)
- error("Invalid syntax in expression near character '%c'.",yychar);
- else
- error("Invalid syntax in expression");
+ error ("A %s in expression, near `%s'.", (msg ? msg : "error"), lexptr);
}
-