diff options
author | Doug Evans <dje@google.com> | 2012-06-04 02:57:28 +0000 |
---|---|---|
committer | Doug Evans <dje@google.com> | 2012-06-04 02:57:28 +0000 |
commit | d790cf0a9cd4ac9c90668788215bb0b7f0095387 (patch) | |
tree | 9f0bb4ab0f1b3f82a49dbabada5d66e814c05912 /gdb/objfiles.h | |
parent | bb3a4c10194fcd2be8963749de7a6b88b6deb2c1 (diff) | |
download | gdb-d790cf0a9cd4ac9c90668788215bb0b7f0095387.zip gdb-d790cf0a9cd4ac9c90668788215bb0b7f0095387.tar.gz gdb-d790cf0a9cd4ac9c90668788215bb0b7f0095387.tar.bz2 |
* objfiles.h (ALL_OBJFILE_PRIMARY_SYMTABS): New macro.
(ALL_PRIMARY_SYMTABS): Use it.
(ALL_PSPACE_PRIMARY_SYMTABS): Ditto.
* dwarf2read.c (dw2_find_symbol_file): Ditto.
* linespec.c (iterate_over_all_matching_symtabs): Ditto.
* symtab.c (lookup_symbol_aux_objfile): Ditto.
(basic_lookup_transparent_type): Ditto.
Diffstat (limited to 'gdb/objfiles.h')
-rw-r--r-- | gdb/objfiles.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/gdb/objfiles.h b/gdb/objfiles.h index d5c807f..98cc39e 100644 --- a/gdb/objfiles.h +++ b/gdb/objfiles.h @@ -556,6 +556,12 @@ extern int gdb_bfd_close_or_warn (struct bfd *abfd); #define ALL_OBJFILE_SYMTABS(objfile, s) \ for ((s) = (objfile) -> symtabs; (s) != NULL; (s) = (s) -> next) +/* Traverse all primary symtabs in one objfile. */ + +#define ALL_OBJFILE_PRIMARY_SYMTABS(objfile, s) \ + ALL_OBJFILE_SYMTABS ((objfile), (s)) \ + if ((s)->primary) + /* Traverse all minimal symbols in one objfile. */ #define ALL_OBJFILE_MSYMBOLS(objfile, m) \ @@ -578,13 +584,11 @@ extern int gdb_bfd_close_or_warn (struct bfd *abfd); #define ALL_PRIMARY_SYMTABS(objfile, s) \ ALL_OBJFILES (objfile) \ - ALL_OBJFILE_SYMTABS (objfile, s) \ - if ((s)->primary) + ALL_OBJFILE_PRIMARY_SYMTABS (objfile, s) #define ALL_PSPACE_PRIMARY_SYMTABS(pspace, objfile, s) \ ALL_PSPACE_OBJFILES (ss, objfile) \ - ALL_OBJFILE_SYMTABS (objfile, s) \ - if ((s)->primary) + ALL_OBJFILE_PRIMARY_SYMTABS (objfile, s) /* Traverse all minimal symbols in all objfiles in the current symbol space. */ |