aboutsummaryrefslogtreecommitdiff
path: root/gdb/stabsread.c
diff options
context:
space:
mode:
authorJim Kingdon <jkingdon@engr.sgi.com>1994-02-03 19:28:30 +0000
committerJim Kingdon <jkingdon@engr.sgi.com>1994-02-03 19:28:30 +0000
commit159ada029b5bea9a8e3f1a67b550e0633f5733bb (patch)
tree3c00b2ad21093142960e39d861b7349df5cdf13f /gdb/stabsread.c
parenta8493f59b7e9c1428aa819eab007e8ab835e4cdc (diff)
downloadgdb-159ada029b5bea9a8e3f1a67b550e0633f5733bb.zip
gdb-159ada029b5bea9a8e3f1a67b550e0633f5733bb.tar.gz
gdb-159ada029b5bea9a8e3f1a67b550e0633f5733bb.tar.bz2
* stabsread.c (read_sun_builtin_type): Skip the semicolon at the end
of the type if present.
Diffstat (limited to 'gdb/stabsread.c')
-rw-r--r--gdb/stabsread.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/gdb/stabsread.c b/gdb/stabsread.c
index 0b18d04..8a786df 100644
--- a/gdb/stabsread.c
+++ b/gdb/stabsread.c
@@ -3043,6 +3043,14 @@ read_sun_builtin_type (pp, typenums, objfile)
type_bits = read_huge_number (pp, 0, &nbits);
if (nbits != 0)
return error_type (pp);
+ /* The type *should* end with a semicolon. If it are embedded
+ in a larger type the semicolon may be the only way to know where
+ the type ends. If this type is at the end of the stabstring we
+ can deal with the omitted semicolon (but we don't have to like
+ it). Don't bother to complain(), Sun's compiler omits the semicolon
+ for "void". */
+ if (**pp == ';')
+ ++(*pp);
return init_type (type_bits == 0 ? TYPE_CODE_VOID : TYPE_CODE_INT,
type_bits / TARGET_CHAR_BIT,