diff options
author | Dawn Perchik <dawn@cygnus> | 1997-09-08 00:38:19 +0000 |
---|---|---|
committer | Dawn Perchik <dawn@cygnus> | 1997-09-08 00:38:19 +0000 |
commit | d719efc6d5435a174fc9dfafff1c6f8d2d7e7c04 (patch) | |
tree | 8076bd277ac84a1efdb026686d59c01de6ac4310 /gdb/symtab.c | |
parent | 60b570d17a8fa5e72665ca8f3a9c98462c66f915 (diff) | |
download | gdb-d719efc6d5435a174fc9dfafff1c6f8d2d7e7c04.zip gdb-d719efc6d5435a174fc9dfafff1c6f8d2d7e7c04.tar.gz gdb-d719efc6d5435a174fc9dfafff1c6f8d2d7e7c04.tar.bz2 |
* dbxread.c, buildsym.c, symtab.c, stabsread.c: Add support for
reading stabs extensions for live range information.
* stabsread.h, partial-stab.h: Add prototypes for new functions.
* symtab.h: Add structure for storing live range information.
Diffstat (limited to 'gdb/symtab.c')
-rw-r--r-- | gdb/symtab.c | 23 |
1 files changed, 19 insertions, 4 deletions
diff --git a/gdb/symtab.c b/gdb/symtab.c index 7edd1a6..9ae6442 100644 --- a/gdb/symtab.c +++ b/gdb/symtab.c @@ -912,6 +912,7 @@ lookup_block_symbol (block, name, namespace) const char *name; const namespace_enum namespace; { + extern struct symbol *ref_search_val (struct symbol *sym, CORE_ADDR addr); register int bot, top, inc; register struct symbol *sym; register struct symbol *sym_found = NULL; @@ -1017,6 +1018,10 @@ lookup_block_symbol (block, name, namespace) if (SYMBOL_NAMESPACE (sym) == namespace && SYMBOL_MATCHES_NAME (sym, name)) { + /* Given pc, search thu alias list to find the active symbol. */ + if (SYMBOL_ALIASES (sym)) + sym = ref_search_val (sym, read_pc ()); + sym_found = sym; if (SYMBOL_CLASS (sym) != LOC_ARG && SYMBOL_CLASS (sym) != LOC_LOCAL_ARG && @@ -2080,15 +2085,25 @@ decode_line_1 (argptr, funfirstline, default_symtab, default_line, canonical) } if (p[0] == ':' || p[0] == ' ' || p[0] == '\t') break; + if (p[0] == '.' && strchr (p, ':') == NULL) /* Java qualified method. */ + { + /* Find the *last* '.', since the others are package qualifiers. */ + for (p1 = p; *p1; p1++) + { + if (*p1 == '.') + p = p1; + } + break; + } } while (p[0] == ' ' || p[0] == '\t') p++; - if ((p[0] == ':') && !has_parens) + if ((p[0] == ':' || p[0] == '.') && !has_parens) { - /* C++ */ + /* C++ or Java */ if (is_quoted) *argptr = *argptr+1; - if (p[1] ==':') + if (p[0] == '.' || p[1] ==':') { /* Extract the class name. */ p1 = p; @@ -2098,7 +2113,7 @@ decode_line_1 (argptr, funfirstline, default_symtab, default_line, canonical) copy[p - *argptr] = 0; /* Discard the class name from the arg. */ - p = p1 + 2; + p = p1 + (p1[0] == ':' ? 2 : 1); while (*p == ' ' || *p == '\t') p++; *argptr = p; |