aboutsummaryrefslogtreecommitdiff
path: root/gdb/c-exp.y
diff options
context:
space:
mode:
authorJohn Gilmore <gnu@cygnus>1992-01-27 22:10:05 +0000
committerJohn Gilmore <gnu@cygnus>1992-01-27 22:10:05 +0000
commit5a4e72150520b0379fc6bce7debd6e98b0b3ec26 (patch)
treeb887ec85bb47bbf7f5ae38ca29a7bdcaff5afa2c /gdb/c-exp.y
parentdc72b0b67900108ef033f0ffabb8e06ffa591e0b (diff)
downloadgdb-5a4e72150520b0379fc6bce7debd6e98b0b3ec26.zip
gdb-5a4e72150520b0379fc6bce7debd6e98b0b3ec26.tar.gz
gdb-5a4e72150520b0379fc6bce7debd6e98b0b3ec26.tar.bz2
* buildsym.c (read_struct_type): Circumvent sun3 sunos "--" compiler bug.
* c-exp.y (yylex): `this' and `template' are only tokens in C++. * target.c (target_xfer_memory): Return errno in preference to EIO.
Diffstat (limited to 'gdb/c-exp.y')
-rw-r--r--gdb/c-exp.y6
1 files changed, 4 insertions, 2 deletions
diff --git a/gdb/c-exp.y b/gdb/c-exp.y
index 7d4b177..6592076 100644
--- a/gdb/c-exp.y
+++ b/gdb/c-exp.y
@@ -1297,7 +1297,8 @@ yylex ()
case 8:
if (!strncmp (tokstart, "unsigned", 8))
return UNSIGNED;
- if (!strncmp (tokstart, "template", 8))
+ if (current_language->la_language == language_cplus
+ && !strncmp (tokstart, "template", 8))
return TEMPLATE;
break;
case 6:
@@ -1319,7 +1320,8 @@ yylex ()
return ENUM;
if (!strncmp (tokstart, "long", 4))
return LONG;
- if (!strncmp (tokstart, "this", 4))
+ if (current_language->la_language == language_cplus
+ && !strncmp (tokstart, "this", 4))
{
static const char this_name[] =
{ CPLUS_MARKER, 't', 'h', 'i', 's', '\0' };