mirror of
https://github.com/bminor/binutils-gdb.git
synced 2025-12-26 01:07:52 +00:00
Remove "struct" from foreach statements
Some versions of gcc have a bug that causes
for (struct mumble : something)
... to give a compiler error. We routinely work around this bug in
gdb, but apparently had not done so in a while. This patch fixes the
remaining known cases of this problem.
gdb/ChangeLog
2019-05-03 Sandra Loosemore <sandra@codesourcery.com>
Tom Tromey <tom@tromey.com>
* dictionary.c (collate_pending_symbols_by_language): Remove
"struct" from foreach.
* symtab.c (lookup_global_symbol_from_objfile)
(lookup_symbol_in_objfile_from_linkage_name): Remove "struct" from
foreach.
* ser-tcp.c (net_open): Remove "struct" from foreach.
* objfiles.c (objfile_relocate, objfile_rebase)
(objfile_has_symbols): Remove "struct" from foreach.
* minsyms.c (lookup_minimal_symbol_by_pc_section): Remove "struct"
from foreach.
* dwarf2read.c (handle_struct_member_die): Remove "struct" from
foreach.
* darwin-nat.c (thread_info_from_private_thread_info): Remove
"struct" from foreach.
* ada-lang.c (create_excep_cond_exprs)
(ada_exception_catchpoint_cond_string): Remove "struct" from
foreach.
This commit is contained in:
@@ -12483,7 +12483,7 @@ create_excep_cond_exprs (struct ada_catchpoint *c,
|
||||
because the expression may hold the addresses of multiple symbols
|
||||
in some cases. */
|
||||
std::multimap<program_space *, struct bp_location *> loc_map;
|
||||
for (struct bp_location *bl = c->loc; bl != NULL; bl = bl->next)
|
||||
for (bp_location *bl = c->loc; bl != NULL; bl = bl->next)
|
||||
loc_map.emplace (bl->pspace, bl);
|
||||
|
||||
scoped_restore_current_program_space save_pspace;
|
||||
@@ -13231,7 +13231,7 @@ ada_exception_catchpoint_cond_string (const char *excep_string,
|
||||
excep_string = ada_encode (excep_string);
|
||||
std::vector<struct bound_minimal_symbol> symbols
|
||||
= ada_lookup_simple_minsyms (excep_string);
|
||||
for (const struct bound_minimal_symbol &msym : symbols)
|
||||
for (const bound_minimal_symbol &msym : symbols)
|
||||
{
|
||||
if (!result.empty ())
|
||||
result += " or ";
|
||||
|
||||
Reference in New Issue
Block a user